From 99f01cdc1f1c19c05a4bf9c02fd91bfbdbd82438 Mon Sep 17 00:00:00 2001 From: "Cohn, Robert S" Date: Mon, 5 Feb 2024 20:00:25 +0100 Subject: [PATCH 1/4] updates for ssf compliance --- .github/workflows/{ci.yml => pr.yml} | 19 +++++---- README.rst | 4 +- docker/Dockerfile | 7 ---- requirements.base.txt | 21 ++++++++++ requirements.txt | 63 ++++++++++++++++++---------- scripts/oneapi.py | 3 -- 6 files changed, 76 insertions(+), 41 deletions(-) rename .github/workflows/{ci.yml => pr.yml} (85%) delete mode 100644 docker/Dockerfile create mode 100644 requirements.base.txt diff --git a/.github/workflows/ci.yml b/.github/workflows/pr.yml similarity index 85% rename from .github/workflows/ci.yml rename to .github/workflows/pr.yml index e37f5ce889..d6a9d8b338 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/pr.yml @@ -2,6 +2,9 @@ # # SPDX-License-Identifier: MIT +name: "PR Tests" +permissions: read-all + on: push: branches: @@ -12,18 +15,18 @@ jobs: checks: runs-on: ${{ github.repository_owner == 'oneapi-src' && 'intel-ubuntu-latest' || 'ubuntu-latest' }} steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@b4ffde6 + - uses: actions/setup-python@0a5c615 with: python-version: '3.10' cache: 'pip' - name: Checks - uses: pre-commit/action@v3.0.0 + uses: pre-commit/action@646c83f build: runs-on: ${{ github.repository_owner == 'oneapi-src' && 'intel-ubuntu-latest' || 'ubuntu-latest' }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@b4ffde6 - name: Install ubuntu prerequisites run: | sudo apt update -qq @@ -31,7 +34,7 @@ jobs: curl -s https://www.doxygen.nl/files/doxygen-1.9.6.linux.bin.tar.gz -o /tmp/dox.tgz sudo tar zxf /tmp/dox.tgz -C /usr/local sudo ln -s /usr/local/doxygen*/bin/* /usr/bin - - uses: actions/setup-python@v4 + - uses: actions/setup-python@0a5c615 with: python-version: '3.10' cache: 'pip' @@ -54,7 +57,7 @@ jobs: cp -r build/html/* site/spec cp build/latex/*.pdf site/spec - name: Archive site - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@26f96df with: name: site path: site @@ -65,12 +68,12 @@ jobs: runs-on: ${{ github.repository_owner == 'oneapi-src' && 'intel-ubuntu-latest' || 'ubuntu-latest' }} steps: - name: Checkout gh-pages - uses: actions/checkout@v3 + uses: actions/checkout@b4ffde6 with: ref: gh-pages path: gh-pages - name: Retrieve site - uses: actions/download-artifact@v3 + uses: actions/download-artifact@6b208ae with: name: site path: gh-pages diff --git a/README.rst b/README.rst index bee3e9e1a0..d335af2143 100644 --- a/README.rst +++ b/README.rst @@ -6,8 +6,8 @@ oneAPI Specifications ===================== -.. image:: https://github.com/oneapi-src/oneAPI-spec/actions/workflows/ci.yml/badge.svg - :target: https://github.com/oneapi-src/oneapi-spec/actions?query=workflow%3ACI +.. image:: https://github.com/oneapi-src/oneAPI-spec/actions/workflows/pr.yml/badge.svg + :target: https://github.com/oneapi-src/oneapi-spec/actions/workflows/pr.yml .. image:: https://api.reuse.software/badge/github.com/oneapi-src/oneapi-spec :target: https://api.reuse.software/info/github.com/oneapi-src/oneapi-spec diff --git a/docker/Dockerfile b/docker/Dockerfile deleted file mode 100644 index e58d7d9444..0000000000 --- a/docker/Dockerfile +++ /dev/null @@ -1,7 +0,0 @@ -# SPDX-FileCopyrightText: 2019-2020 Intel Corporation -# -# SPDX-License-Identifier: MIT - -FROM ubuntu:20.04 -COPY ubuntu-packages.txt install.sh requirements.txt /tmp/ -RUN cd /tmp && ./install.sh diff --git a/requirements.base.txt b/requirements.base.txt new file mode 100644 index 0000000000..f2ae13848c --- /dev/null +++ b/requirements.base.txt @@ -0,0 +1,21 @@ +# SPDX-FileCopyrightText: 2019-2020 Intel Corporation +# +# SPDX-License-Identifier: MIT + +# This is the minimal set of components required and using the latest +# versions + +breathe +graphviz +lxml +six +Sphinx +sphinx-notfound-page +sphinx-book-theme +sphinx-prompt +sphinx_substitution_extensions +sphinx_tabs +sphinxcontrib.plantuml +sphinxcontrib-spelling +sphinxcontrib-svg2pdfconverter +sphinxmark diff --git a/requirements.txt b/requirements.txt index f2ae13848c..77f6cdde32 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,21 +1,42 @@ -# SPDX-FileCopyrightText: 2019-2020 Intel Corporation -# -# SPDX-License-Identifier: MIT - -# This is the minimal set of components required and using the latest -# versions - -breathe -graphviz -lxml -six -Sphinx -sphinx-notfound-page -sphinx-book-theme -sphinx-prompt -sphinx_substitution_extensions -sphinx_tabs -sphinxcontrib.plantuml -sphinxcontrib-spelling -sphinxcontrib-svg2pdfconverter -sphinxmark +accessible-pygments==0.0.4 +alabaster==0.7.16 +Babel==2.14.0 +beautifulsoup4==4.12.3 +bottle==0.12.25 +breathe==4.35.0 +certifi==2024.2.2 +charset-normalizer==3.3.2 +docutils==0.20.1 +graphviz==0.20.1 +idna==3.6 +imagesize==1.4.1 +Jinja2==3.1.3 +lxml==5.1.0 +MarkupSafe==2.1.5 +packaging==23.2 +pillow==10.2.0 +pydata-sphinx-theme==0.15.2 +pyenchant==3.2.2 +Pygments==2.17.2 +requests==2.31.0 +six==1.16.0 +snowballstemmer==2.2.0 +soupsieve==2.5 +Sphinx==7.2.6 +sphinx-book-theme==1.1.0 +sphinx-notfound-page==1.0.0 +sphinx-prompt==1.8.0 +Sphinx-Substitution-Extensions==2022.2.16 +sphinx-tabs==3.4.5 +sphinxcontrib-applehelp==1.0.8 +sphinxcontrib-devhelp==1.0.6 +sphinxcontrib-htmlhelp==2.0.5 +sphinxcontrib-jsmath==1.0.1 +sphinxcontrib-plantuml==0.27 +sphinxcontrib-qthelp==1.0.7 +sphinxcontrib-serializinghtml==1.1.10 +sphinxcontrib-spelling==8.0.0 +sphinxcontrib-svg2pdfconverter==1.2.2 +sphinxmark==1.0.0 +typing_extensions==4.9.0 +urllib3==2.2.0 diff --git a/scripts/oneapi.py b/scripts/oneapi.py index 9b8cd6295a..13151d1f09 100644 --- a/scripts/oneapi.py +++ b/scripts/oneapi.py @@ -94,8 +94,6 @@ def sphinx(root, target): sphinx_args = '-N' if not cl_args.verbose: sphinx_args += ' -q' - if not cl_args.serial: - sphinx_args += ' -j auto' if cl_args.a: sphinx_args += ' -a' if cl_args.n: @@ -272,7 +270,6 @@ def main(): parser.add_argument('--branch') parser.add_argument('--verbose', action='store_true') parser.add_argument('--dry-run', action='store_true') - parser.add_argument('--serial', action='store_true') parser.add_argument('-W', action='store_true') parser.add_argument( '-a', action='store_true', help='sphinx -a (build all files)' From ff7d4df2c968cc4a2cc5f80c5c97cad35f4d4f39 Mon Sep 17 00:00:00 2001 From: "Cohn, Robert S" Date: Mon, 5 Feb 2024 20:06:57 +0100 Subject: [PATCH 2/4] ssf compliance updates --- .#requirements.header.txt | 1 + requirements.base.txt | 1 + requirements.header.txt | 15 +++++++++++++++ requirements.txt | 24 ++++++++++++++++++++++++ 4 files changed, 41 insertions(+) create mode 120000 .#requirements.header.txt create mode 100644 requirements.header.txt diff --git a/.#requirements.header.txt b/.#requirements.header.txt new file mode 120000 index 0000000000..441b15144a --- /dev/null +++ b/.#requirements.header.txt @@ -0,0 +1 @@ +rscohn1@gkdse-fcp-19.igk.intel.com.21327:1707144085 \ No newline at end of file diff --git a/requirements.base.txt b/requirements.base.txt index f2ae13848c..01ba4e8c98 100644 --- a/requirements.base.txt +++ b/requirements.base.txt @@ -8,6 +8,7 @@ breathe graphviz lxml +pre-commit six Sphinx sphinx-notfound-page diff --git a/requirements.header.txt b/requirements.header.txt new file mode 100644 index 0000000000..eb296e13e5 --- /dev/null +++ b/requirements.header.txt @@ -0,0 +1,15 @@ +# SPDX-FileCopyrightText: 2019-2020 Intel Corporation +# +# SPDX-License-Identifier: MIT + +# This file is generated with: +# +# rm -rf venv +# python -m venv venv +# source venv/bin/activate +# pip install -r requirements.base.txt +# cp requirements.header.txt requirements.txt +# pip freeze >> requirements.txt +# +# Add this header, including copyright back +# diff --git a/requirements.txt b/requirements.txt index 77f6cdde32..2e4fc1fc8d 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,3 +1,18 @@ +# SPDX-FileCopyrightText: 2019-2020 Intel Corporation +# +# SPDX-License-Identifier: MIT + +# This file is generated with: +# +# rm -rf venv +# python -m venv venv +# source venv/bin/activate +# pip install -r requirements.base.txt +# cp requirements.header.txt requirements.txt +# pip freeze >> requirements.txt +# +# Add this header, including copyright back +# accessible-pygments==0.0.4 alabaster==0.7.16 Babel==2.14.0 @@ -5,19 +20,27 @@ beautifulsoup4==4.12.3 bottle==0.12.25 breathe==4.35.0 certifi==2024.2.2 +cfgv==3.4.0 charset-normalizer==3.3.2 +distlib==0.3.8 docutils==0.20.1 +filelock==3.13.1 graphviz==0.20.1 +identify==2.5.33 idna==3.6 imagesize==1.4.1 Jinja2==3.1.3 lxml==5.1.0 MarkupSafe==2.1.5 +nodeenv==1.8.0 packaging==23.2 pillow==10.2.0 +platformdirs==4.2.0 +pre-commit==3.6.0 pydata-sphinx-theme==0.15.2 pyenchant==3.2.2 Pygments==2.17.2 +PyYAML==6.0.1 requests==2.31.0 six==1.16.0 snowballstemmer==2.2.0 @@ -40,3 +63,4 @@ sphinxcontrib-svg2pdfconverter==1.2.2 sphinxmark==1.0.0 typing_extensions==4.9.0 urllib3==2.2.0 +virtualenv==20.25.0 From fbb4659ade1173c62b41ba19f284c06090470e36 Mon Sep 17 00:00:00 2001 From: "Cohn, Robert S" Date: Mon, 5 Feb 2024 20:08:14 +0100 Subject: [PATCH 3/4] update --- .#requirements.header.txt | 1 - 1 file changed, 1 deletion(-) delete mode 120000 .#requirements.header.txt diff --git a/.#requirements.header.txt b/.#requirements.header.txt deleted file mode 120000 index 441b15144a..0000000000 --- a/.#requirements.header.txt +++ /dev/null @@ -1 +0,0 @@ -rscohn1@gkdse-fcp-19.igk.intel.com.21327:1707144085 \ No newline at end of file From 47a2a5541a110144887221f7e45b9ca3d4e65fcf Mon Sep 17 00:00:00 2001 From: "Cohn, Robert S" Date: Mon, 5 Feb 2024 21:14:57 +0100 Subject: [PATCH 4/4] update --- .github/workflows/pr.yml | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml index d6a9d8b338..0bab432298 100644 --- a/.github/workflows/pr.yml +++ b/.github/workflows/pr.yml @@ -15,18 +15,18 @@ jobs: checks: runs-on: ${{ github.repository_owner == 'oneapi-src' && 'intel-ubuntu-latest' || 'ubuntu-latest' }} steps: - - uses: actions/checkout@b4ffde6 - - uses: actions/setup-python@0a5c615 + - uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 + - uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c with: python-version: '3.10' cache: 'pip' - name: Checks - uses: pre-commit/action@646c83f + uses: pre-commit/action@646c83fcd040023954eafda54b4db0192ce70507 build: runs-on: ${{ github.repository_owner == 'oneapi-src' && 'intel-ubuntu-latest' || 'ubuntu-latest' }} steps: - - uses: actions/checkout@b4ffde6 + - uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 - name: Install ubuntu prerequisites run: | sudo apt update -qq @@ -34,7 +34,7 @@ jobs: curl -s https://www.doxygen.nl/files/doxygen-1.9.6.linux.bin.tar.gz -o /tmp/dox.tgz sudo tar zxf /tmp/dox.tgz -C /usr/local sudo ln -s /usr/local/doxygen*/bin/* /usr/bin - - uses: actions/setup-python@0a5c615 + - uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c with: python-version: '3.10' cache: 'pip' @@ -57,7 +57,7 @@ jobs: cp -r build/html/* site/spec cp build/latex/*.pdf site/spec - name: Archive site - uses: actions/upload-artifact@26f96df + uses: actions/upload-artifact@26f96dfa697d77e81fd5907df203aa23a56210a8 with: name: site path: site @@ -68,12 +68,12 @@ jobs: runs-on: ${{ github.repository_owner == 'oneapi-src' && 'intel-ubuntu-latest' || 'ubuntu-latest' }} steps: - name: Checkout gh-pages - uses: actions/checkout@b4ffde6 + uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 with: ref: gh-pages path: gh-pages - name: Retrieve site - uses: actions/download-artifact@6b208ae + uses: actions/download-artifact@6b208ae046db98c579e8a3aa621ab581ff575935 with: name: site path: gh-pages