diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000..a857c4d --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,11 @@ +version: 2 +updates: + # Maintain dependencies for GitHub Actions + - package-ecosystem: "github-actions" + directory: "/" + schedule: + interval: "daily" + - package-ecosystem: "pip" + directory: "/tools" # Location of package manifests + schedule: + interval: "daily" \ No newline at end of file diff --git a/.github/workflows/pymarkdownlnt.yml b/.github/workflows/pymarkdownlnt.yml new file mode 100644 index 0000000..7fb2422 --- /dev/null +++ b/.github/workflows/pymarkdownlnt.yml @@ -0,0 +1,30 @@ +name: Pymarkdownlnt +# Runs the workflow on the below events: +# 1. on pull request raised to trunk branch. +# 2. on push event to trunk branch. +on: + push: + branches: + - trunk + pull_request: + branches: + - trunk + +permissions: # added using https://github.com/step-security/secure-workflows + contents: read + +jobs: + lint-markdown: + runs-on: ubuntu-latest + name: Lint Markdown + steps: + - name: Set up Python + uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c # v5.0.0 + with: + python-version: 3.9 #install the python needed + - name: checkout repo content + uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 + - name: Install and run linter + run: |- + python3 -m pip install --require-hashes -r tools/requirements.txt + pymarkdownlnt scan */*.md diff --git a/.github/workflows/update_python_requirements.yml b/.github/workflows/update_python_requirements.yml new file mode 100644 index 0000000..3b8aabc --- /dev/null +++ b/.github/workflows/update_python_requirements.yml @@ -0,0 +1,51 @@ +name: Bump requirements.txt +on: + pull_request: + paths: + - 'tools/pyproject.toml' + workflow_dispatch: + +permissions: + pull-requests: write + +jobs: + bump_requirements: + runs-on: ubuntu-latest + + steps: + - name: Checkout this repo + if: ${{ github.actor == 'dependabot[bot]' }} + uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 + with: + fetch-depth: 0 + ref: ${{ github.event.pull_request.head.ref }} + token: ${{ secrets.MY_GITHUB_TOKEN }} + + - name: Set up Python + if: ${{ github.actor == 'dependabot[bot]' }} + uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c # v5.0.0 + with: + python-version: '3.11' + + - name: Install Poetry + if: ${{ github.actor == 'dependabot[bot]' }} + uses: abatilo/actions-poetry@7b6d33e44b4f08d7021a1dee3c044e9c253d6439 # v3.0.0 + with: + poetry-version: '1.7.1' + + - name: Bump Python dependencies + if: ${{ github.actor == 'dependabot[bot]' }} + run: | + cd tools + poetry update + poetry export --format requirements.txt --output requirements.txt + git config --global user.name 'dependabot[bot]' + git config --global user.email 'dependabot[bot]@users.noreply.github.com' + git add requirements.txt + if [ -z "$(git status --porcelain)" ]; then + echo 'No changes to commit on this run' + exit 0 + else + git commit -m "build(deps): Bump requirements.txt" + git push + fi diff --git a/docs/OpenSSF_scorecards.md b/docs/OpenSSF_scorecards.md index f12821c..f4f5a84 100644 --- a/docs/OpenSSF_scorecards.md +++ b/docs/OpenSSF_scorecards.md @@ -6,6 +6,7 @@ we've implemented [Open Source Security Foundation Scorecards](https://securityscorecards.dev/) on key repos: + | Repo | OpenSSF scorecard | |---|---| | [at_c](https://github.com/atsign-foundation/at_c) | [![OpenSSF Scorecard](https://api.securityscorecards.dev/projects/github.com/atsign-foundation/at_c/badge)](https://api.securityscorecards.dev/projects/github.com/atsign-foundation/at_c) | diff --git a/docs/atGitHub.md b/docs/atGitHub.md index 90e1c8d..d1ecb8e 100644 --- a/docs/atGitHub.md +++ b/docs/atGitHub.md @@ -138,9 +138,12 @@ to ensure that INFO level findings don't break tests. [pymarkdownlnt](https://pypi.org/project/pymarkdownlnt/). If you're working on Markdown docs then it's recommended to have pymarkdownlnt installed in a virtual environment. +[This post](https://blog.thestateofme.com/2024/02/16/linting-markdown-with-pymarkdownlnt/) +provides details on setting things up. * Python (and MicroPython) use either [Flake8](https://flake8.pycqa.org/en/latest/) or [Ruff](https://docs.astral.sh/ruff/) +* Rust uses [clippy](https://github.com/rust-lang/rust-clippy) ### Continuous Delivery diff --git a/profile/README.md b/profile/README.md index 7e92424..2dbf3df 100644 --- a/profile/README.md +++ b/profile/README.md @@ -1,3 +1,4 @@ +

The Atsign Foundation @@ -15,15 +16,18 @@ repos for [Atsign's technology](https://docs.atsign.com/). ## Our Most Important Repos + |Products Built on the Tech|| |-|-| | [![Atsign Foundation No Ports-Light](https://github-readme-stats.vercel.app/api/pin?username=atsign-foundation&repo=noports&hide_border=true&bg_color=00000000&theme=default#gh-light-mode-only)](https://github.com/atsign-foundation/noports#gh-light-mode-only)[![Atsign Foundation No Ports-Dark](https://github-readme-stats.vercel.app/api/pin?username=atsign-foundation&repo=noports&hide_border=true&theme=dark&bg_color=00000000#gh-dark-mode-only)](https://github.com/atsign-foundation/noports#gh-dark-mode-only) | [![Atsign Foundation atmospherePro-Light](https://github-readme-stats.vercel.app/api/pin?username=atsign-foundation&repo=atmosphere_pro&hide_border=true&bg_color=00000000&theme=default#gh-light-mode-only)](https://github.com/atsign-foundation/atmosphere_pro#gh-light-mode-only)[![Atsign Foundation atmospherePro-Dark](https://github-readme-stats.vercel.app/api/pin?username=atsign-foundation&repo=atmosphere_pro&hide_border=true&theme=dark&bg_color=00000000#gh-dark-mode-only)](https://github.com/atsign-foundation/atmosphere_pro#gh-dark-mode-only) | + |Core Tech & Libraries|| |-|-| | [![Atsign Foundation atServer-Light](https://github-readme-stats.vercel.app/api/pin?username=atsign-foundation&repo=at_server&hide_border=true&bg_color=00000000&theme=default#gh-light-mode-only)](https://github.com/atsign-foundation/at_server#gh-light-mode-only)[![Atsign Foundation atServer-Dark](https://github-readme-stats.vercel.app/api/pin?username=atsign-foundation&repo=at_server&hide_border=true&theme=dark&bg_color=00000000#gh-dark-mode-only)](https://github.com/atsign-foundation/at_server#gh-dark-mode-only) | [![Atsign Foundation atClient-Light](https://github-readme-stats.vercel.app/api/pin?username=atsign-foundation&repo=at_client_sdk&hide_border=true&bg_color=00000000&theme=default#gh-light-mode-only)](https://github.com/atsign-foundation/at_client_sdk#gh-light-mode-only)[![Atsign Foundation atClient-Dark](https://github-readme-stats.vercel.app/api/pin?username=atsign-foundation&repo=at_client_sdk&hide_border=true&theme=dark&bg_color=00000000#gh-dark-mode-only)](https://github.com/atsign-foundation/at_client_sdk#gh-dark-mode-only) | | [![Atsign Foundation atLibraries-Light](https://github-readme-stats.vercel.app/api/pin?username=atsign-foundation&repo=at_libraries&hide_border=true&bg_color=00000000&theme=default#gh-light-mode-only)](https://github.com/atsign-foundation/at_libraries#gh-light-mode-only)[![Atsign Foundation atLibraries-Dark](https://github-readme-stats.vercel.app/api/pin?username=atsign-foundation&repo=at_libraries&hide_border=true&theme=dark&bg_color=00000000#gh-dark-mode-only)](https://github.com/atsign-foundation/at_libraries#gh-dark-mode-only) | [![Atsign Foundation atWidgets-Light](https://github-readme-stats.vercel.app/api/pin?username=atsign-foundation&repo=at_widgets&hide_border=true&bg_color=00000000&theme=default#gh-light-mode-only)](https://github.com/atsign-foundation/at_widgets#gh-light-mode-only)[![Atsign Foundation atWidgets-Dark](https://github-readme-stats.vercel.app/api/pin?username=atsign-foundation&repo=at_widgets&hide_border=true&theme=dark&bg_color=00000000#gh-dark-mode-only)](https://github.com/atsign-foundation/at_widgets#gh-dark-mode-only) | + | Documentation & Tools || |-|-| | [![Atsign Foundation atProtocol-Light](https://github-readme-stats.vercel.app/api/pin?username=atsign-foundation&repo=at_protocol&hide_border=true&bg_color=00000000&theme=default#gh-light-mode-only)](https://github.com/atsign-foundation/at_protocol#gh-light-mode-only)[![Atsign Foundation atProtocol-Dark](https://github-readme-stats.vercel.app/api/pin?username=atsign-foundation&repo=at_protocol&hide_border=true&theme=dark&bg_color=00000000#gh-dark-mode-only)](https://github.com/atsign-foundation/at_protocol#gh-dark-mode-only) | [![Atsign Foundation Docs-Light](https://github-readme-stats.vercel.app/api/pin?username=atsign-foundation&repo=docs.atsign.com&hide_border=true&bg_color=00000000&theme=default#gh-light-mode-only)](https://github.com/atsign-foundation/docs.atsign.com#gh-light-mode-only)[![Atsign Foundation Docs-Dark](https://github-readme-stats.vercel.app/api/pin?username=atsign-foundation&repo=docs.atsign.com&hide_border=true&theme=dark&bg_color=00000000#gh-dark-mode-only)](https://github.com/atsign-foundation/docs.atsign.com#gh-dark-mode-only) | @@ -32,6 +36,7 @@ repos for [Atsign's technology](https://docs.atsign.com/). ## Available SDKS + [![Dart](https://img.shields.io/badge/Dart-Stable-Informational?style=for-the-badge&color=blue&logo=Dart)](https://github.com/atsign-foundation/at_client_sdk) [![Java](https://img.shields.io/badge/Java-Stable-Informational?style=for-the-badge&color=blue&logo=Oracle)](https://github.com/atsign-foundation/at_java) [![MicroPython](https://img.shields.io/badge/MicroPython-Beta-Informational?style=for-the-badge&color=yellow&logo=micropython)](https://github.com/atsign-foundation/at_pico_w) @@ -43,12 +48,14 @@ repos for [Atsign's technology](https://docs.atsign.com/). ## How we use GitHub + [![How we use GitHub Documentation](https://img.shields.io/badge/How_we_use_GitHub-black?style=for-the-badge&logo=github)](https://github.com/atsign-foundation/.github/blob/trunk/docs/atGitHub.md) [![OpenSSF Scorecards](https://img.shields.io/badge/OpenSSF_ScoreCards-black?style=for-the-badge&logo=github)](https://github.com/atsign-foundation/.github/blob/trunk/docs/OpenSSF_scorecards.md) [![at_mono: a synthetic monorepo](https://img.shields.io/badge/at_mono:_a_synthetic_monorepo-black?style=for-the-badge&logo=github)](https://github.com/atsign-foundation/.github/blob/trunk/docs/at_mono.md) ## We are proud to sponsor + EFF Org Member Global Encryption Coalition Lora Alliance diff --git a/tools/pyproject.toml b/tools/pyproject.toml new file mode 100644 index 0000000..4cd6b22 --- /dev/null +++ b/tools/pyproject.toml @@ -0,0 +1,15 @@ +[tool.poetry] +name = "at-protocol-tools" +version = "0.1.0" +description = "" +authors = ["Chris Swan <@cpswan>"] +readme = "README.md" +packages = [{include = "at_protocol_tools"}] + +[tool.poetry.dependencies] +python = "^3.8" +pymarkdownlnt = "^0.9.14" + +[build-system] +requires = ["poetry-core"] +build-backend = "poetry.core.masonry.api" diff --git a/tools/requirements.txt b/tools/requirements.txt new file mode 100644 index 0000000..de1116b --- /dev/null +++ b/tools/requirements.txt @@ -0,0 +1,62 @@ +application-properties==0.8.1 ; python_version >= "3.8" and python_version < "4.0" \ + --hash=sha256:101667125383940651e72a2a9b3aa32225f359050c3be45b4ef4b51009930bb4 \ + --hash=sha256:f442e403ab7c8f97b048cf0ab92845057d595989653f65ced48579ad7cf35607 +columnar==1.4.1 ; python_version >= "3.8" and python_version < "4.0" \ + --hash=sha256:8efb692a7e6ca07dcc8f4ea889960421331a5dffa8e5af81f0a67ad8ea1fc798 \ + --hash=sha256:c3cb57273333b2ff9cfaafc86f09307419330c97faa88dcfe23df05e6fbb9c72 +pymarkdownlnt==0.9.15 ; python_version >= "3.8" and python_version < "4.0" \ + --hash=sha256:a6e432efc0070ac173a597abf07d99df0f33efcd8cc7a89d190d3cd46380b8b2 \ + --hash=sha256:ab109d43cd2e6e7ff723217574f2ed72785c1582d0501630d7a3c2f568d92924 +pyyaml==6.0.1 ; python_version >= "3.8" and python_version < "4.0" \ + --hash=sha256:062582fca9fabdd2c8b54a3ef1c978d786e0f6b3a1510e0ac93ef59e0ddae2bc \ + --hash=sha256:1635fd110e8d85d55237ab316b5b011de701ea0f29d07611174a1b42f1444741 \ + --hash=sha256:184c5108a2aca3c5b3d3bf9395d50893a7ab82a38004c8f61c258d4428e80206 \ + --hash=sha256:18aeb1bf9a78867dc38b259769503436b7c72f7a1f1f4c93ff9a17de54319b27 \ + --hash=sha256:1d4c7e777c441b20e32f52bd377e0c409713e8bb1386e1099c2415f26e479595 \ + --hash=sha256:1e2722cc9fbb45d9b87631ac70924c11d3a401b2d7f410cc0e3bbf249f2dca62 \ + --hash=sha256:1fe35611261b29bd1de0070f0b2f47cb6ff71fa6595c077e42bd0c419fa27b98 \ + --hash=sha256:28c119d996beec18c05208a8bd78cbe4007878c6dd15091efb73a30e90539696 \ + --hash=sha256:42f8152b8dbc4fe7d96729ec2b99c7097d656dc1213a3229ca5383f973a5ed6d \ + --hash=sha256:4fb147e7a67ef577a588a0e2c17b6db51dda102c71de36f8549b6816a96e1867 \ + --hash=sha256:50550eb667afee136e9a77d6dc71ae76a44df8b3e51e41b77f6de2932bfe0f47 \ + --hash=sha256:510c9deebc5c0225e8c96813043e62b680ba2f9c50a08d3724c7f28a747d1486 \ + --hash=sha256:5773183b6446b2c99bb77e77595dd486303b4faab2b086e7b17bc6bef28865f6 \ + --hash=sha256:596106435fa6ad000c2991a98fa58eeb8656ef2325d7e158344fb33864ed87e3 \ + --hash=sha256:6965a7bc3cf88e5a1c3bd2e0b5c22f8d677dc88a455344035f03399034eb3007 \ + --hash=sha256:69b023b2b4daa7548bcfbd4aa3da05b3a74b772db9e23b982788168117739938 \ + --hash=sha256:704219a11b772aea0d8ecd7058d0082713c3562b4e271b849ad7dc4a5c90c13c \ + --hash=sha256:7e07cbde391ba96ab58e532ff4803f79c4129397514e1413a7dc761ccd755735 \ + --hash=sha256:81e0b275a9ecc9c0c0c07b4b90ba548307583c125f54d5b6946cfee6360c733d \ + --hash=sha256:9046c58c4395dff28dd494285c82ba00b546adfc7ef001486fbf0324bc174fba \ + --hash=sha256:9eb6caa9a297fc2c2fb8862bc5370d0303ddba53ba97e71f08023b6cd73d16a8 \ + --hash=sha256:a0cd17c15d3bb3fa06978b4e8958dcdc6e0174ccea823003a106c7d4d7899ac5 \ + --hash=sha256:afd7e57eddb1a54f0f1a974bc4391af8bcce0b444685d936840f125cf046d5bd \ + --hash=sha256:b1275ad35a5d18c62a7220633c913e1b42d44b46ee12554e5fd39c70a243d6a3 \ + --hash=sha256:b786eecbdf8499b9ca1d697215862083bd6d2a99965554781d0d8d1ad31e13a0 \ + --hash=sha256:ba336e390cd8e4d1739f42dfe9bb83a3cc2e80f567d8805e11b46f4a943f5515 \ + --hash=sha256:baa90d3f661d43131ca170712d903e6295d1f7a0f595074f151c0aed377c9b9c \ + --hash=sha256:bc1bf2925a1ecd43da378f4db9e4f799775d6367bdb94671027b73b393a7c42c \ + --hash=sha256:bd4af7373a854424dabd882decdc5579653d7868b8fb26dc7d0e99f823aa5924 \ + --hash=sha256:bf07ee2fef7014951eeb99f56f39c9bb4af143d8aa3c21b1677805985307da34 \ + --hash=sha256:bfdf460b1736c775f2ba9f6a92bca30bc2095067b8a9d77876d1fad6cc3b4a43 \ + --hash=sha256:c8098ddcc2a85b61647b2590f825f3db38891662cfc2fc776415143f599bb859 \ + --hash=sha256:d2b04aac4d386b172d5b9692e2d2da8de7bfb6c387fa4f801fbf6fb2e6ba4673 \ + --hash=sha256:d858aa552c999bc8a8d57426ed01e40bef403cd8ccdd0fc5f6f04a00414cac2a \ + --hash=sha256:f003ed9ad21d6a4713f0a9b5a7a0a79e08dd0f221aff4525a2be4c346ee60aab \ + --hash=sha256:f22ac1c3cac4dbc50079e965eba2c1058622631e526bd9afd45fedd49ba781fa \ + --hash=sha256:faca3bdcf85b2fc05d06ff3fbc1f83e1391b3e724afa3feba7d13eeab355484c \ + --hash=sha256:fca0e3a251908a499833aa292323f32437106001d436eca0e6e7833256674585 \ + --hash=sha256:fd1592b3fdf65fff2ad0004b5e363300ef59ced41c2e6b3a99d4089fa8c5435d \ + --hash=sha256:fd66fc5d0da6d9815ba2cebeb4205f95818ff4b79c3ebe268e75d961704af52f +tomli==2.0.1 ; python_version >= "3.8" and python_version < "4.0" \ + --hash=sha256:939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc \ + --hash=sha256:de526c12914f0c550d15924c62d72abc48d6fe7364aa87328337a31007fe8a4f +toolz==0.12.0 ; python_version >= "3.8" and python_version < "4.0" \ + --hash=sha256:2059bd4148deb1884bb0eb770a3cde70e7f954cfbbdc2285f1f2de01fd21eb6f \ + --hash=sha256:88c570861c440ee3f2f6037c4654613228ff40c93a6c25e0eba70d17282c6194 +typing-extensions==4.9.0 ; python_version >= "3.8" and python_version < "4.0" \ + --hash=sha256:23478f88c37f27d76ac8aee6c905017a143b0b1b886c3c9f66bc2fd94f9f5783 \ + --hash=sha256:af72aea155e91adfc61c3ae9e0e342dbc0cba726d6cba4b6c72c1f34e47291cd +wcwidth==0.2.12 ; python_version >= "3.8" and python_version < "4.0" \ + --hash=sha256:f01c104efdf57971bcb756f054dd58ddec5204dd15fa31d6503ea57947d97c02 \ + --hash=sha256:f26ec43d96c8cbfed76a5075dac87680124fa84e0855195a6184da9c187f133c