File tree Expand file tree Collapse file tree 2 files changed +9
-17
lines changed Expand file tree Collapse file tree 2 files changed +9
-17
lines changed Original file line number Diff line number Diff line change 7
7
create :
8
8
tags :
9
9
- ' *'
10
+
11
+ env :
12
+ FORCE_COLOR : 1
13
+
10
14
jobs :
11
15
check :
12
16
runs-on : ubuntu-latest
31
35
runs-on : ubuntu-latest
32
36
steps :
33
37
- uses : actions/checkout@v3
38
+ with :
39
+ fetch-depth : 0
34
40
- name : Set up Python
35
41
uses : actions/setup-python@v4
36
42
with :
95
101
path : dist
96
102
- name : Install downloaded wheel
97
103
run : |
98
- python -m pip install dist/sphinxext_opengraph-main-py3-none-any.whl
104
+ python -m pip install --no-index --find-links=dist sphinxext-opengraph
99
105
- name : Run tests for ${{ matrix.python-version }}
100
106
run : |
101
107
python -m pytest -vv
Original file line number Diff line number Diff line change 1
- import subprocess
2
-
3
1
import setuptools
4
2
5
- # This will fail if something happens or if not in a git repository.
6
- # This is intentional.
7
- try :
8
- ret = subprocess .run (
9
- "git describe --tags --abbrev=0" ,
10
- capture_output = True ,
11
- check = True ,
12
- shell = True ,
13
- )
14
- version = ret .stdout .decode ("utf-8" ).strip ()
15
- except :
16
- version = "main"
17
-
18
3
with open ("README.md" , encoding = "utf-8" ) as readme :
19
4
long_description = readme .read ()
20
5
21
6
setuptools .setup (
22
7
name = "sphinxext-opengraph" ,
23
- version = version ,
8
+ use_scm_version = True ,
9
+ setup_requires = ["setuptools_scm" ],
24
10
author = "Itay Ziv" ,
25
11
26
12
description = "Sphinx Extension to enable OGP support" ,
You can’t perform that action at this time.
0 commit comments