Skip to content

Commit 6ef5fb7

Browse files
author
alex-treebeard
committed
fixes
1 parent 8151e37 commit 6ef5fb7

5 files changed

Lines changed: 338 additions & 31 deletions

File tree

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,13 @@ jobs:
1212
steps:
1313
- uses: actions/checkout@v2
1414
- uses: actions/setup-python@v2
15-
- run: npm i --global vsce
1615
- run: pip install poetry
1716
- run: echo "ref is $GITHUB_REF"
1817
- run: poetry version ${GITHUB_REF:10}
1918
- run: poetry build
2019
- run: pip install twine
2120
- run: twine upload dist/* -ualex-treebeard -p${{ secrets.PYPI_PASSWORD }}
22-
- name: publish extension
23-
run: cd .. && yarn && yarn version --no-git-tag-version --new-version ${GITHUB_REF:10} && vsce publish
21+
- run: yarn && yarn run publish '${GITHUB_REF:10}'
2422
env:
2523
VSCE_PAT: ${{ secrets.VSCE_PAT }}
2624
- uses: EndBug/add-and-commit@v7.0.0

.github/workflows/test-publish-to-pypi.yml

Lines changed: 0 additions & 25 deletions
This file was deleted.

.github/workflows/test.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,3 +65,22 @@ jobs:
6565
- run: vsce package
6666
env:
6767
VSCE_PAT: ${{ secrets.VSCE_PAT }}
68+
69+
build-n-publish:
70+
defaults:
71+
run:
72+
working-directory: python-cli
73+
runs-on: macos-latest
74+
steps:
75+
- uses: actions/checkout@v2
76+
- uses: actions/setup-python@v2
77+
- run: pip install poetry
78+
- run: |
79+
build_version="$(poetry version -s).dev$(date +%s)"
80+
echo $build_version
81+
poetry version $build_version
82+
- run: poetry build
83+
- run: pip install "dist/pytest-deepcov-$(poetry version -s).tar.gz"
84+
- run: pip install twine
85+
- run: ls -la dist
86+
- run: twine upload --repository testpypi dist/* -ualex-treebeard-test -p${{ secrets.TEST_PYPI_PASSWORD }}

package.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@
4646
"mocha": "^8.2.1",
4747
"prettier": "^2.2.1",
4848
"typescript": "^4.1.3",
49+
"vsce": "^1.87.0",
4950
"vscode-test": "^1.5.0"
5051
},
5152
"displayName": "Deepcov",
@@ -74,6 +75,8 @@
7475
"scripts": {
7576
"compile": "tsc -p ./ && yarn run lint",
7677
"lint": "eslint src --ext ts",
78+
"package": "yarn run vsce package",
79+
"publish": "yarn version --no-git-tag-version --new-version && yarn run vsce publish",
7780
"test": "node ./out/test/runTest.js",
7881
"vscode:prepublish": "yarn run compile",
7982
"watch": "tsc -watch -p ./"

0 commit comments

Comments
 (0)