Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions .github/workflows/docs-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,13 @@ jobs:
python-version: [3.12]

steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Checkout repository
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false # do not keep the token around

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: ${{ matrix.python-version }}

Expand Down
10 changes: 7 additions & 3 deletions .github/workflows/pypi-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,13 @@ jobs:
runs-on: ubuntu-24.04

steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
- name: Checkout repository
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false # do not keep the token around

- name: Set up Python 3.12
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: 3.12

Expand Down
8 changes: 7 additions & 1 deletion src/commoncode/system.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@ def os_arch():
os = "mac"
elif "freebsd" in sys_platform:
os = "freebsd"
elif "sunos" in sys_platform:
os = "sunos"
elif "haiku" in sys_platform:
os = "haiku"
else:
raise Exception("Unsupported OS/platform %r" % sys_platform)
return os, arch
Expand All @@ -45,7 +49,9 @@ def os_arch():
on_mac = current_os == "mac"
on_linux = current_os == "linux"
on_freebsd = current_os == "freebsd"
on_posix = not on_windows and (on_mac or on_linux or on_freebsd)
on_sunos = current_os == "sunos"
on_haiku = current_os == "haiku"
on_posix = not on_windows and (on_mac or on_linux or on_freebsd or on_sunos or on_haiku)

current_os_arch = "%(current_os)s-%(current_arch)s" % locals()
noarch = "noarch"
Expand Down