diff --git a/.github/assets/.copier-answers.yml b/.github/assets/.copier-answers.yml new file mode 100644 index 0000000..b9b24e1 --- /dev/null +++ b/.github/assets/.copier-answers.yml @@ -0,0 +1,32 @@ +# Changes here will be overwritten by Copier; NEVER EDIT MANUALLY +_src_path: ./project +author_email: 45483159+twsl@users.noreply.github.com +author_username: twsl +copyright_holder: twsl +copyright_holder_email: 45483159+twsl@users.noreply.github.com +copyright_license: MIT +copyright_year: 2024 +custom_install: true +github_runner: +- ubuntu-latest +github_runner_python_version: +- '3.11' +- '3.12' +include_copilot: false +include_databricks: false +include_docs: true +include_notebooks: true +include_sample_code: false +line_ending: lf +primary_branch: main +project_description: '' +project_name: example-project +python_package_command_line_name: example-project +python_package_distribution_name: example-project +python_package_import_name: example_project +python_version: '3.11' +repository_name: example-project +repository_namespace: twsl +repository_provider: github.com +self_signed: false +use_precommit: true diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml new file mode 100644 index 0000000..e887cf0 --- /dev/null +++ b/.github/workflows/build.yaml @@ -0,0 +1,48 @@ +name: Build + +on: + push: + pull_request: + workflow_dispatch: + +jobs: + build-and-test: + name: Build and Test + runs-on: ubuntu-latest + defaults: + run: + shell: bash + + steps: + - name: Checkout + uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: "3.11" + + - name: Install Poetry + uses: snok/install-poetry@v1 + with: + virtualenvs-create: true + virtualenvs-in-project: true + + - name: Add poetry to path + run: echo "$(poetry env info --path)/bin" >> $GITHUB_PATH + + - name: Set up cache + uses: actions/cache@v4 + id: cached-poetry-dependencies + with: + path: .venv + key: venv-${{ runner.os }}-${{ hashFiles('poetry.lock') }} + + - name: Install dependencies + if: steps.cached-poetry-dependencies.outputs.cache-hit != 'true' + run: poetry install --no-interaction + + - name: Test + run: poetry run copier copy -a ./.github/assets/.copier-answers.yml --force ./project ./dist