Skip to content

Commit

Permalink
update 9 files and delete 5 files
Browse files Browse the repository at this point in the history
  • Loading branch information
MartinBernstorff committed Feb 20, 2024
1 parent 537d4bc commit 9a1b434
Show file tree
Hide file tree
Showing 29 changed files with 634 additions and 546 deletions.
11 changes: 11 additions & 0 deletions .copier-answers.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Changes here will be overwritten by Copier; NEVER EDIT MANUALLY
_commit: 01e7745
_src_path: https://github.com/MartinBernstorff/nimble-python-template
email: martinbernstorff@gmail.com
full_name: Martin Bernstorff
github_username: MartinBernstorff
package_name: iterpy
project_name: iterpy
project_slug: iterpy
python_version: '3.9'
release_to_pypi: true
25 changes: 1 addition & 24 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,31 +6,8 @@
// Sets the run context to one level up instead of the .devcontainer folder.
"context": "..",
// Update the 'dockerFile' property if you aren't using the standard 'Dockerfile' filename.
"dockerfile": "../Dockerfile",
"cacheFrom": "ghcr.io/martinbernstorff/iter-devcontainer:latest"
"dockerfile": "../Dockerfile"
},
// "features": {},
"customizations": {
"vscode": {
"extensions": [
"GitHub.copilot",
"charliermarsh.ruff",
"ms-python.python",
"ms-python.vscode-pylance",
"GitHub.vscode-pull-request-github",
"ms-vscode.makefile-tools",
"github.vscode-github-actions",
"MichaelCurrin.auto-commit-msg"
]
}
},
"mounts": [
"source=${localEnv:HOME}/.config/gh/hosts.yml,target=/root/.config/gh/hosts.yml,type=bind,consistency=cache", // GitHub CLI authentication login
],
"features": {
"ghcr.io/devcontainers/features/github-cli:1": {}
},
"postStartCommand": "gt user pager --disable && pip install -e .[dev,benchmark]"
// Features to add to the dev container. More info: https://containers.dev/features.
// "features": {},
// Use 'forwardPorts' to make a list of ports inside the container available locally.
Expand Down
27 changes: 0 additions & 27 deletions .github/workflows/check_for_rej.yml

This file was deleted.

16 changes: 0 additions & 16 deletions .github/workflows/dependabot.yml

This file was deleted.

30 changes: 0 additions & 30 deletions .github/workflows/dependabot_automerge.yml

This file was deleted.

21 changes: 7 additions & 14 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,42 +1,35 @@
name: Release
on:
workflow_run:
workflows: ["Tests"]
workflows: ["test"]
types:
- completed
# Manual trigger
workflow_dispatch:


jobs:
release:
runs-on: ubuntu-latest
concurrency: release
permissions:
id-token: write # IMPORTANT: this permission is mandatory for trusted publishing using PyPI
# a guide on how to set it up is available here: https://blog.pypi.org/posts/2023-04-20-introducing-trusted-publishers/

# A guide on how to set it up is available here: https://blog.pypi.org/posts/2023-04-20-introducing-trusted-publishers/
# You can add a new publisher here: https://pypi.org/manage/account/publishing/

if: ${{ github.ref == 'refs/heads/main' && github.event.workflow_run.conclusion == 'success'}}
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
fetch-depth: 0
token: ${{ secrets.PAT }}

- name: Python Semantic Release
id: release
uses: python-semantic-release/python-semantic-release@v8.0.4
uses: python-semantic-release/python-semantic-release@v9.1.0
with:
github_token: ${{ secrets.PAT }}

- name: Publish package distributions to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
if: steps.release.outputs.released == 'true'
# This action supports PyPI's trusted publishing implementation, which allows authentication to PyPI without a manually
# configured API token or username/password combination. To perform trusted publishing with this action, your project's
# publisher must already be configured on PyPI.

- name: Publish package distributions to GitHub Releases
uses: python-semantic-release/upload-to-gh-release@main
if: steps.release.outputs.released == 'true'
with:
github_token: ${{ secrets.PAT }}
23 changes: 0 additions & 23 deletions .github/workflows/stalebot.yml

This file was deleted.

32 changes: 32 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# This workflow will install Python dependencies, run pytests and run notebooks
# then it will in python 3.9 (ubuntu-latest) create a badge with the coverage
# and add it to the PR. This badge will be updated if the PR is updated.

name: tests
on:
push:
branches: [main]
pull_request:

jobs:
test:
permissions: write-all
runs-on: ubuntu-latest
steps:
- name: Checkout (GitHub)
uses: actions/checkout@v3

- name: Login to GitHub Container Registry
uses: docker/login-action@v2
with:
registry: ghcr.io
username:
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build dev container and run CI
uses: devcontainers/ci@v0.3
with:
imageName: ghcr.io/aarhus-psychiatry-research/psycop-common
push: filter
runCmd: |
make validate_ci
48 changes: 0 additions & 48 deletions .github/workflows/tests.yml

This file was deleted.

Loading

0 comments on commit 9a1b434

Please sign in to comment.