From 12a6b4a8b2855e596bfb45807e5e478c30428336 Mon Sep 17 00:00:00 2001 From: Sepehr Karimiziarani <112987653+sepehrkrz@users.noreply.github.com> Date: Mon, 30 Oct 2023 13:58:05 -0500 Subject: [PATCH 1/2] Delete .github/workflows directory --- .github/workflows/python-publish.yml | 44 ---------------------------- 1 file changed, 44 deletions(-) delete mode 100644 .github/workflows/python-publish.yml diff --git a/.github/workflows/python-publish.yml b/.github/workflows/python-publish.yml deleted file mode 100644 index 20608ed..0000000 --- a/.github/workflows/python-publish.yml +++ /dev/null @@ -1,44 +0,0 @@ -name: Deploy to PyPI - -on: - pull_request: - types: - - closed - -jobs: - deploy: - runs-on: ubuntu-latest - environment: production - steps: - - name: var APP_ID - run: echo " My App ID is ${{ vars.APP_KEY }}" - - - name: SECRET API_KEY - run: echo " My secret ID is ${{ secrets.PYPI_API_TOKEN }}" - - - name: Checkout code - uses: actions/checkout@v2 - - - name: Set up Python - uses: actions/setup-python@v2 - with: - python-version: 3.x - - - name: Print Repository URL - run: | - REPO_URL="https://github.com/${{ github.repository }}" - echo "Repository URL: $REPO_URL" - - - name: Install dependencies - run: pip install setuptools wheel - - name: List Secrets - run: | - echo "Available secrets:" - env - - - name: Build and deploy package - run: | - python setup.py sdist bdist_wheel - pip install twine==4.0.2 - echo "PYPI_API_TOKEN: ${{ secrets.SEPEHR }}" # Print the API token - twine upload -u '__token__' -p ${{ secrets.PYPI_API_TOKEN }} dist/* From aa0cb8ea7fcc8655a30a1e51dbafdd13b272edd0 Mon Sep 17 00:00:00 2001 From: Sepehr Karimiziarani <112987653+sepehrkrz@users.noreply.github.com> Date: Mon, 30 Oct 2023 14:01:16 -0500 Subject: [PATCH 2/2] Create python-publish.yml --- .github/workflows/python-publish.yml | 34 ++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 .github/workflows/python-publish.yml diff --git a/.github/workflows/python-publish.yml b/.github/workflows/python-publish.yml new file mode 100644 index 0000000..195188d --- /dev/null +++ b/.github/workflows/python-publish.yml @@ -0,0 +1,34 @@ +name: Publish nwmurl to PYPI + +on: + pull_request: + types: + - closed + +jobs: + deploy: + runs-on: ubuntu-latest + environment: production + steps: + + - name: Checkout code + uses: actions/checkout@v2 + + - name: Set up Python + uses: actions/setup-python@v2 + with: + python-version: 3.x + + - name: Print Repository URL + run: | + REPO_URL="https://github.com/${{ github.repository }}" + echo "Repository URL: $REPO_URL" + + - name: Install dependencies + run: pip install setuptools wheel + + - name: Build and deploy package + run: | + python setup.py sdist bdist_wheel + pip install twine==4.0.2 + twine upload -u '__token__' -p ${{ secrets.PYPI_API_TOKEN }} dist/*