17 [davidbrownell] on Initial #17
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ---------------------------------------------------------------------- | ||
# | | ||
# | standard.yaml | ||
# | | ||
# | David Brownell <[email protected]> | ||
# | 2024-01-02 18:15:54 | ||
# | | ||
# ---------------------------------------------------------------------- | ||
# | | ||
# | Copyright David Brownell 2024 | ||
# | Distributed under the Boost Software License, Version 1.0. See | ||
# | accompanying file LICENSE_1_0.txt or copy at | ||
# | http://www.boost.org/LICENSE_1_0.txt. | ||
# | | ||
# ---------------------------------------------------------------------- | ||
name: "Standard" | ||
run-name: ${{ github.run_number }} [${{ github.actor }}] on ${{ github.ref_name }} | ||
on: | ||
pull_request: | ||
branches: | ||
- main | ||
push: | ||
branches: | ||
- main | ||
schedule: | ||
- cron: '0 0 * * *' # Once a day at 12am UTC | ||
workflow_dispatch: | ||
jobs: | ||
standard: | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: | ||
- macos-latest | ||
- ubuntu-latest | ||
- windows-latest | ||
python_version: | ||
- "3.12" | ||
- "3.11" | ||
- "3.10" | ||
# - "3.9" # Not supported | ||
# - "3.8" # Not supported | ||
name: "Validate (${{ matrix.os }}; py${{ matrix.python_version }})" | ||
runs-on: ${{ matrix.os }} | ||
env: | ||
COLUMNS: "200" | ||
SIMULATE_TERMINAL_CAPABILITIES_SUPPORTS_COLORS: "1" | ||
PYTHONIOENCODING: "UTF-8" | ||
steps: | ||
# Ensure that windows machines support long paths | ||
- name: git Long File Path Support on Windows | ||
if: ${{ startsWith(matrix.os, 'windows') }} | ||
run: |- | ||
git config --system core.longpaths true | ||
- name: "Checkout Source" | ||
uses: actions/checkout@v4 | ||
- name: Initialize | ||
id: Initialize | ||
uses: davidbrownell/PythonBootstrapper/.github/actions/initialize@main | ||
with: | ||
operating_system: ${{ matrix.os }} | ||
- name: Validate | ||
uses: ./.github/actions/validate | ||
with: | ||
operating_system: ${{ matrix.os }} | ||
python_version: ${{ matrix.python_version }} | ||
script_prefix: ${{ steps.initialize.outputs.script_prefix }} | ||
script_extension: ${{ steps.initialize.outputs.script_extension }} | ||
shell_name: ${{ steps.initialize.outputs.shell_name }} | ||
source_command: ${{ steps.initialize.outputs.source_command }} | ||
sudo_command: ${{ steps.initialize.outputs.sudo_command }} | ||
package: | ||
needs: standard | ||
name: "Package" | ||
runs-on: ubuntu-latest | ||
env: | ||
COLUMNS: "200" | ||
SIMULATE_TERMINAL_CAPABILITIES_SUPPORTS_COLORS: "1" | ||
PYTHONIOENCODING: "UTF-8" | ||
steps: | ||
- name: "Checkout Source" | ||
uses: actions/checkout@v4 | ||
- name: Initialize | ||
id: Initialize | ||
uses: davidbrownell/PythonBootstrapper/.github/actions/initialize@main | ||
with: | ||
operating_system: ${{ matrix.os }} | ||
- name: Bootstrap | ||
shell: ${{ inputs.shell_name }} | ||
Check failure on line 105 in .github/workflows/standard.yaml GitHub Actions / StandardInvalid workflow file
|
||
run: |- | ||
${{ inputs.script_prefix }}Bootstrap${{ inputs.script_extension }} --python-version ${{ inputs.python_version }} | ||
- name: Update Version | ||
shell: ${{ inputs.shell_name }} | ||
run: |- | ||
${{ inputs.source_command }} ${{ inputs.script_prefix }}Activate${{ inputs.script_extension }} | ||
python Build.py UpdateVersion | ||
- name: Package | ||
shell: ${{ inputs.shell_name }} | ||
run: |- | ||
${{ inputs.source_command }} ${{ inputs.script_prefix }}Activate${{ inputs.script_extension }} | ||
python Build.py Package | ||
# TODO: Upload package | ||
# TODO: Publish package (if push to main) |