Skip to content

Commit ab26347

Browse files
Merge latest skeleton changes
Signed-off-by: Ayan Sinha Mahapatra <ayansmahapatra@gmail.com>
1 parent db9dd08 commit ab26347

33 files changed

+483
-680
lines changed

.github/workflows/docs-ci.yml

Lines changed: 9 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -4,34 +4,29 @@ on: [push, pull_request]
44

55
jobs:
66
build:
7-
runs-on: ubuntu-20.04
7+
runs-on: ubuntu-24.04
88

99
strategy:
1010
max-parallel: 4
1111
matrix:
12-
python-version: [3.9]
12+
python-version: [3.12]
1313

1414
steps:
1515
- name: Checkout code
16-
uses: actions/checkout@v3
16+
uses: actions/checkout@v4
1717

1818
- name: Set up Python ${{ matrix.python-version }}
19-
uses: actions/setup-python@v4
19+
uses: actions/setup-python@v5
2020
with:
2121
python-version: ${{ matrix.python-version }}
2222

23-
- name: Give permission to run scripts
24-
run: chmod +x ./docs/scripts/doc8_style_check.sh
25-
2623
- name: Install Dependencies
27-
run: pip install -e .[docs]
24+
run: ./configure --dev
2825

29-
- name: Check Sphinx Documentation build minimally
30-
working-directory: ./docs
31-
run: sphinx-build -E -W source build
26+
- name: Check documentation and HTML for errors and dead links
27+
run: make docs-check
3228

33-
- name: Check for documentation style errors
34-
working-directory: ./docs
35-
run: ./scripts/doc8_style_check.sh
29+
- name: Check documentation for style errors
30+
run: make doc8
3631

3732

.github/workflows/pypi-release.yml

Lines changed: 15 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -21,23 +21,26 @@ on:
2121
jobs:
2222
build-pypi-distribs:
2323
name: Build and publish library to PyPI
24-
runs-on: ubuntu-20.04
24+
runs-on: ubuntu-24.04
2525

2626
steps:
27-
- uses: actions/checkout@v3
27+
- uses: actions/checkout@v4
2828
- name: Set up Python
29-
uses: actions/setup-python@v4
29+
uses: actions/setup-python@v5
3030
with:
31-
python-version: 3.9
31+
python-version: 3.12
3232

33-
- name: Install pypa/build
34-
run: python -m pip install build --user
33+
- name: Install pypa/build and twine
34+
run: python -m pip install --user build twine
3535

3636
- name: Build a binary wheel and a source tarball
3737
run: python -m build --sdist --wheel --outdir dist/
3838

39+
- name: Validate wheel and sdis for Pypi
40+
run: python -m twine check dist/*
41+
3942
- name: Upload built archives
40-
uses: actions/upload-artifact@v3
43+
uses: actions/upload-artifact@v4
4144
with:
4245
name: pypi_archives
4346
path: dist/*
@@ -47,17 +50,17 @@ jobs:
4750
name: Create GH release
4851
needs:
4952
- build-pypi-distribs
50-
runs-on: ubuntu-20.04
53+
runs-on: ubuntu-24.04
5154

5255
steps:
5356
- name: Download built archives
54-
uses: actions/download-artifact@v3
57+
uses: actions/download-artifact@v4
5558
with:
5659
name: pypi_archives
5760
path: dist
5861

5962
- name: Create GH release
60-
uses: softprops/action-gh-release@v1
63+
uses: softprops/action-gh-release@v2
6164
with:
6265
draft: true
6366
files: dist/*
@@ -67,11 +70,11 @@ jobs:
6770
name: Create PyPI release
6871
needs:
6972
- create-gh-release
70-
runs-on: ubuntu-20.04
73+
runs-on: ubuntu-24.04
7174

7275
steps:
7376
- name: Download built archives
74-
uses: actions/download-artifact@v3
77+
uses: actions/download-artifact@v4
7578
with:
7679
name: pypi_archives
7780
path: dist

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,3 +72,5 @@ tcl
7272

7373
# Ignore Jupyter Notebook related temp files
7474
.ipynb_checkpoints/
75+
/.ruff_cache/
76+
.env

.readthedocs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,4 +26,4 @@ python:
2626
- method: pip
2727
path: .
2828
extra_requirements:
29-
- docs
29+
- dev

AUTHORS.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,5 @@ The following organizations or individuals have contributed to this repo:
1010
- Qingmin Duanmu @qduanmu
1111
- Rakesh Balusa @balusarakesh
1212
- Ravi Jain @JRavi2
13-
- Steven Esser @majurg
13+
- Steven Esser @majurg
14+

MANIFEST.in

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,26 @@
11
graft src
2+
graft docs
3+
graft etc
24

35
include *.LICENSE
46
include NOTICE
57
include *.ABOUT
68
include *.toml
79
include *.yml
810
include *.rst
11+
include *.png
912
include setup.*
1013
include configure*
1114
include requirements*
1215
include .giti*
16+
include .dockerignore
17+
include .gitignore
18+
include .readthedocs.yml
19+
include manage.py
20+
include Dockerfile*
21+
include Makefile
22+
include MANIFEST.in
1323

14-
include extractcode*
24+
include .VERSION
1525

1626
global-exclude *.py[co] __pycache__ *.*~
17-

Makefile

Lines changed: 26 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# ScanCode is a trademark of nexB Inc.
55
# SPDX-License-Identifier: Apache-2.0
66
# See http://www.apache.org/licenses/LICENSE-2.0 for the license text.
7-
# See https://github.com/nexB/skeleton for support or download.
7+
# See https://github.com/aboutcode-org/skeleton for support or download.
88
# See https://aboutcode.org for more information about nexB OSS projects.
99
#
1010

@@ -13,31 +13,33 @@ PYTHON_EXE?=python3
1313
VENV=venv
1414
ACTIVATE?=. ${VENV}/bin/activate;
1515

16-
dev:
17-
@echo "-> Configure the development envt."
18-
./configure --dev
1916

20-
isort:
21-
@echo "-> Apply isort changes to ensure proper imports ordering"
22-
${VENV}/bin/isort --sl -l 100 src tests setup.py
17+
conf:
18+
@echo "-> Install dependencies"
19+
./configure
2320

24-
black:
25-
@echo "-> Apply black code formatter"
26-
${VENV}/bin/black -l 100 src tests setup.py
21+
dev:
22+
@echo "-> Configure and install development dependencies"
23+
./configure --dev
2724

2825
doc8:
2926
@echo "-> Run doc8 validation"
30-
@${ACTIVATE} doc8 --max-line-length 100 --ignore-path docs/_build/ --quiet docs/
27+
@${ACTIVATE} doc8 --quiet docs/ *.rst
3128

32-
valid: isort black
29+
valid:
30+
@echo "-> Run Ruff format"
31+
@${ACTIVATE} ruff format
32+
@echo "-> Run Ruff linter"
33+
@${ACTIVATE} ruff check --fix
3334

3435
check:
35-
@echo "-> Run pycodestyle (PEP8) validation"
36-
@${ACTIVATE} pycodestyle --max-line-length=100 --exclude=.eggs,venv,lib,thirdparty,docs,migrations,settings.py,.cache .
37-
@echo "-> Run isort imports ordering validation"
38-
@${ACTIVATE} isort --sl --check-only -l 100 setup.py src tests .
39-
@echo "-> Run black validation"
40-
@${ACTIVATE} black --check --check -l 100 src tests setup.py
36+
@echo "-> Run Ruff linter validation (pycodestyle, bandit, isort, and more)"
37+
@${ACTIVATE} ruff check
38+
@echo "-> Run Ruff format validation"
39+
@${ACTIVATE} ruff format --check
40+
@$(MAKE) doc8
41+
@echo "-> Run ABOUT files validation"
42+
@${ACTIVATE} about check etc/
4143

4244
clean:
4345
@echo "-> Clean the Python env"
@@ -49,6 +51,10 @@ test:
4951

5052
docs:
5153
rm -rf docs/_build/
52-
@${ACTIVATE} sphinx-build docs/ docs/_build/
54+
@${ACTIVATE} sphinx-build docs/source docs/_build/
55+
56+
docs-check:
57+
@${ACTIVATE} sphinx-build -E -W -b html docs/source docs/_build/
58+
@${ACTIVATE} sphinx-build -E -W -b linkcheck docs/source docs/_build/
5359

54-
.PHONY: conf dev check valid black isort clean test docs
60+
.PHONY: conf dev check valid clean test docs docs-check

NOTICE

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,5 @@
33
# ScanCode is a trademark of nexB Inc.
44
# SPDX-License-Identifier: Apache-2.0
55
# See http://www.apache.org/licenses/LICENSE-2.0 for the license text.
6-
# See https://github.com/nexB/extractcode for support or download.
7-
# See https://aboutcode.org for more information about nexB OSS projects.
8-
#
6+
# Visit https://aboutcode.org and https://github.com/aboutcode-org/ for support and download.
7+
#

README.rst

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ ExtractCode
44

55
- license: Apache-2.0
66
- copyright: copyright (c) nexB. Inc. and others
7-
- homepage_url: https://github.com/nexB/extractcode
7+
- homepage_url: https://github.com/aboutcode-org/extractcode
88
- keywords: archive, extraction, libarchive, 7zip, scancode-toolkit, extractcode
99

1010
Supports Windows, Linux and macOS on 64 bits processors and Python 3.6 to 3.9.
@@ -83,12 +83,12 @@ libmagic) to select the most appropriate extractor or decompressor function.
8383
It can handle multi-level archives such as tar.gz and can extract recursively
8484
any nested archives.
8585

86-
Visit https://aboutcode.org and https://github.com/nexB/ for support and download.
86+
Visit https://aboutcode.org and https://github.com/aboutcode-org/ for support and download.
8787

8888

8989
We run CI tests on:
9090

91-
- Azure pipelines https://dev.azure.com/nexB/extractcode/_build
91+
- Azure pipelines https://dev.azure.com/aboutcode-org/extractcode/_build
9292

9393

9494
Installation
@@ -109,7 +109,7 @@ In this case, you will need to provide a working and compatible libarchive and
109109
find them:
110110

111111
- **a typecode-libarchive and typecode-7z plugin**: See the standard ones at
112-
https://github.com/nexB/scancode-plugins/tree/main/builtins
112+
https://github.com/aboutcode-org/scancode-plugins/tree/main/builtins
113113
These can either bundle a libarchive library, a 7z executable or expose a
114114
system-installed libraries.
115115
It does so by providing plugin entry points as ``scancode_location_provider``
@@ -121,8 +121,8 @@ find them:
121121

122122
See for example:
123123

124-
- https://github.com/nexB/scancode-plugins/blob/4da5fe8a5ab1c87b9b4af9e54d7ad60e289747f5/builtins/extractcode_libarchive-linux/setup.py#L40
125-
- https://github.com/nexB/scancode-plugins/blob/4da5fe8a5ab1c87b9b4af9e54d7ad60e289747f5/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/__init__.py#L17
124+
- https://github.com/aboutcode-org/scancode-plugins/blob/4da5fe8a5ab1c87b9b4af9e54d7ad60e289747f5/builtins/extractcode_libarchive-linux/setup.py#L40
125+
- https://github.com/aboutcode-org/scancode-plugins/blob/4da5fe8a5ab1c87b9b4af9e54d7ad60e289747f5/builtins/extractcode_libarchive-linux/src/extractcode_libarchive/__init__.py#L17
126126

127127
And in the same way, the ``scancode_location_provider`` for ``extractcode_7zip``
128128
should point to a ``LocationProviderPlugin`` subclass with a ``get_locations()``
@@ -132,8 +132,8 @@ find them:
132132

133133
See for example:
134134

135-
- https://github.com/nexB/scancode-plugins/blob/4da5fe8a5ab1c87b9b4af9e54d7ad60e289747f5/builtins/extractcode_7z-linux/setup.py#L40
136-
- https://github.com/nexB/scancode-plugins/blob/4da5fe8a5ab1c87b9b4af9e54d7ad60e289747f5/builtins/extractcode_7z-linux/src/extractcode_7z/__init__.py#L18
135+
- https://github.com/aboutcode-org/scancode-plugins/blob/4da5fe8a5ab1c87b9b4af9e54d7ad60e289747f5/builtins/extractcode_7z-linux/setup.py#L40
136+
- https://github.com/aboutcode-org/scancode-plugins/blob/4da5fe8a5ab1c87b9b4af9e54d7ad60e289747f5/builtins/extractcode_7z-linux/src/extractcode_7z/__init__.py#L18
137137

138138
- use **environment variables** to point to installed binaries:
139139

@@ -181,14 +181,14 @@ ExtractCode will use these environment variables if set:
181181
- EXTRACTCODE_LIBARCHIVE_PATH : the path to the ``libarchive.so`` libarchive
182182
shared library used to support some of the archive formats. If not provided,
183183
ExtractCode will look for a plugin-provided libarchive library path. See
184-
https://github.com/nexB/scancode-plugins/tree/main/builtins for such plugins.
184+
https://github.com/aboutcode-org/scancode-plugins/tree/main/builtins for such plugins.
185185
If no plugin contributes libarchive, then a final attempt is made to look for
186186
it in the PATH using standard DLL loading techniques.
187187

188188
- EXTRACTCODE_7Z_PATH : the path to the ``7z`` 7zip executable used to support
189189
some of the archive formats. If not provided, ExtractCode will look for a
190190
plugin-provided 7z executable path. See
191-
https://github.com/nexB/scancode-plugins/tree/main/builtins for such plugins.
191+
https://github.com/aboutcode-org/scancode-plugins/tree/main/builtins for such plugins.
192192
If no plugin contributes 7z, then a final attempt is made to look for
193193
it in the PATH.
194194

azure-pipelines.yml

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@
77
jobs:
88
- template: etc/ci/azure-posix.yml
99
parameters:
10-
job_name: ubuntu20_cpython
11-
image_name: ubuntu-20.04
12-
python_versions: ["3.8", "3.9", "3.10", "3.11"]
10+
job_name: ubuntu24_cpython
11+
image_name: ubuntu-24.04
12+
python_versions: ["3.9", "3.10", "3.11", "3.12", "3.13"]
1313
test_suites:
1414
all:
1515
sudo chmod 0644 /boot/vmlinuz-* && sudo apt install libguestfs-tools
@@ -19,38 +19,38 @@ jobs:
1919
parameters:
2020
job_name: ubuntu22_cpython
2121
image_name: ubuntu-22.04
22-
python_versions: ["3.8", "3.9", "3.10", "3.11"]
22+
python_versions: ["3.9", "3.10", "3.11", "3.12", "3.13"]
2323
test_suites:
2424
all: venv/bin/pytest -n 2 -vvs
2525

2626
- template: etc/ci/azure-posix.yml
2727
parameters:
28-
job_name: macos12_cpython
29-
image_name: macos-12
30-
python_versions: ["3.8", "3.9", "3.10", "3.11"]
28+
job_name: macos14_cpython
29+
image_name: macos-14
30+
python_versions: ["3.9", "3.10", "3.11", "3.12", "3.13"]
3131
test_suites:
3232
all: venv/bin/pytest -n 2 -vvs
3333

3434
- template: etc/ci/azure-posix.yml
3535
parameters:
3636
job_name: macos13_cpython
3737
image_name: macos-13
38-
python_versions: ["3.8", "3.9", "3.10", "3.11"]
38+
python_versions: ["3.9", "3.10", "3.11", "3.12", "3.13"]
3939
test_suites:
4040
all: venv/bin/pytest -n 2 -vvs
4141

4242
- template: etc/ci/azure-win.yml
4343
parameters:
4444
job_name: win2019_cpython
4545
image_name: windows-2019
46-
python_versions: ["3.8", "3.9", "3.10", "3.11"]
46+
python_versions: ["3.9", "3.10", "3.11", "3.12", "3.13"]
4747
test_suites:
4848
all: venv\Scripts\pytest -n 2 -vvs
4949

5050
- template: etc/ci/azure-win.yml
5151
parameters:
5252
job_name: win2022_cpython
5353
image_name: windows-2022
54-
python_versions: ["3.8", "3.9", "3.10", "3.11"]
54+
python_versions: ["3.9", "3.10", "3.11", "3.12", "3.13"]
5555
test_suites:
5656
all: venv\Scripts\pytest -n 2 -vvs

0 commit comments

Comments
 (0)