From 7e7883df765b5154c7a5f0e60c77e1dca41e0c3e Mon Sep 17 00:00:00 2001 From: chvmvd Date: Sat, 10 Dec 2022 12:31:01 +0900 Subject: [PATCH 01/20] =?UTF-8?q?GitHub=20Actions=E3=82=92=E3=82=B3?= =?UTF-8?q?=E3=83=B3=E3=83=9D=E3=83=BC=E3=83=8D=E3=83=B3=E3=83=88=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/actions/build/build.yml | 24 ++++++++++++++++++++++++ .github/workflows/build-test.yml | 20 ++------------------ .github/workflows/deploy.yml | 6 ++---- .github/workflows/preview.yml | 6 ++---- 4 files changed, 30 insertions(+), 26 deletions(-) create mode 100644 .github/actions/build/build.yml diff --git a/.github/actions/build/build.yml b/.github/actions/build/build.yml new file mode 100644 index 000000000..ff3c10715 --- /dev/null +++ b/.github/actions/build/build.yml @@ -0,0 +1,24 @@ +runs: + name: Build + using: "Composite" + steps: + - name: Setup Node.js + uses: actions/setup-node@v3 + with: + node-version: latest + + - name: Cache Node Modules + uses: actions/cache@v3 + id: node_modules_cache_id + with: + path: "**/node_modules" + key: ${{ runner.os }}-${{ hashFiles('**/package-lock.json') }} + + - name: Install Node Modules + if: steps.node_modules_cache_id.outputs.cache-hit != 'true' + run: npm ci + shell: bash + + - name: Build + run: npm run build + shell: bash diff --git a/.github/workflows/build-test.yml b/.github/workflows/build-test.yml index e8039e8c3..959e4f41e 100644 --- a/.github/workflows/build-test.yml +++ b/.github/workflows/build-test.yml @@ -13,21 +13,5 @@ jobs: - name: Checkout Code uses: actions/checkout@v3 - - name: Setup Node.js - uses: actions/setup-node@v3 - with: - node-version: latest - - - name: Cache Node Modules - uses: actions/cache@v3 - id: node_modules_cache_id - with: - path: "**/node_modules" - key: ${{ runner.os }}-${{ hashFiles('**/package-lock.json') }} - - - name: Install Node Modules - if: steps.node_modules_cache_id.outputs.cache-hit != 'true' - run: npm ci - - - name: Build Test - run: npm run build + - name: Build + uses: ./../actions/build diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 97846de43..42b864d2b 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -17,10 +17,8 @@ jobs: - name: Checkout Code uses: actions/checkout@v3 - - name: Install and Build ๐Ÿ”ง - run: | - npm ci - npm run build + - name: Build + uses: ./../actions/build - name: Deploy ๐Ÿš€ uses: JamesIves/github-pages-deploy-action@v4 diff --git a/.github/workflows/preview.yml b/.github/workflows/preview.yml index bf229739f..db1730ab5 100644 --- a/.github/workflows/preview.yml +++ b/.github/workflows/preview.yml @@ -19,10 +19,8 @@ jobs: - name: Checkout Code uses: actions/checkout@v3 - - name: Install and Build - run: | - npm ci - npm run build + - name: Build + uses: ./../actions/build - name: Deploy preview uses: rossjrw/pr-preview-action@v1 From 5e44b35196191a08d17d7652788b4e977be61568 Mon Sep 17 00:00:00 2001 From: chvmvd Date: Sat, 10 Dec 2022 12:33:36 +0900 Subject: [PATCH 02/20] Fix bug in actions --- .github/workflows/build-test.yml | 2 +- .github/workflows/deploy.yml | 2 +- .github/workflows/preview.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-test.yml b/.github/workflows/build-test.yml index 959e4f41e..a8021ba8b 100644 --- a/.github/workflows/build-test.yml +++ b/.github/workflows/build-test.yml @@ -14,4 +14,4 @@ jobs: uses: actions/checkout@v3 - name: Build - uses: ./../actions/build + uses: ./.github/actions/build diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 42b864d2b..2874b7bcb 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -18,7 +18,7 @@ jobs: uses: actions/checkout@v3 - name: Build - uses: ./../actions/build + uses: ./.github/actions/build - name: Deploy ๐Ÿš€ uses: JamesIves/github-pages-deploy-action@v4 diff --git a/.github/workflows/preview.yml b/.github/workflows/preview.yml index db1730ab5..c1ad14f32 100644 --- a/.github/workflows/preview.yml +++ b/.github/workflows/preview.yml @@ -20,7 +20,7 @@ jobs: uses: actions/checkout@v3 - name: Build - uses: ./../actions/build + uses: ./.github/actions/build - name: Deploy preview uses: rossjrw/pr-preview-action@v1 From 5c4c13ea9fa8c2211d01cbfab2e05f3b27118733 Mon Sep 17 00:00:00 2001 From: chvmvd Date: Sat, 10 Dec 2022 12:38:47 +0900 Subject: [PATCH 03/20] Fix bug in actions --- .github/actions/build/{build.yml => action.yml} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename .github/actions/build/{build.yml => action.yml} (100%) diff --git a/.github/actions/build/build.yml b/.github/actions/build/action.yml similarity index 100% rename from .github/actions/build/build.yml rename to .github/actions/build/action.yml From e946a82b350bb333d4567ba39145c361527ec701 Mon Sep 17 00:00:00 2001 From: chvmvd Date: Sat, 10 Dec 2022 12:44:24 +0900 Subject: [PATCH 04/20] Fix bug in Actions --- .github/actions/build/action.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/actions/build/action.yml b/.github/actions/build/action.yml index ff3c10715..f197de250 100644 --- a/.github/actions/build/action.yml +++ b/.github/actions/build/action.yml @@ -1,5 +1,4 @@ runs: - name: Build using: "Composite" steps: - name: Setup Node.js From e3f68663f277c58673c2547de0d91880c44d05b2 Mon Sep 17 00:00:00 2001 From: chvmvd Date: Sat, 10 Dec 2022 12:48:22 +0900 Subject: [PATCH 05/20] disable preview GitHub Actions --- .github/workflows/preview.yml | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/.github/workflows/preview.yml b/.github/workflows/preview.yml index c1ad14f32..ac7676485 100644 --- a/.github/workflows/preview.yml +++ b/.github/workflows/preview.yml @@ -1,13 +1,15 @@ --- name: Deploy PR previews -# on: -# pull_request: -# types: -# - opened -# - reopened -# - synchronize -# - closed +on: + pull_request: + types: + - opened + - reopened + - synchronize + - closed + branches-ignore: + - "**" concurrency: preview-${{ github.ref }} From 9e5e5e26039bebbc6cc26d7df0a721d6662641a6 Mon Sep 17 00:00:00 2001 From: chvmvd Date: Sat, 10 Dec 2022 21:51:47 +0900 Subject: [PATCH 06/20] Introduce Poetry --- pyproject.toml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 pyproject.toml diff --git a/pyproject.toml b/pyproject.toml new file mode 100644 index 000000000..f384eca78 --- /dev/null +++ b/pyproject.toml @@ -0,0 +1,16 @@ +[tool.poetry] +name = "sikepuri-of-algorithm" +version = "0.1.0" +description = "" +authors = ["chvmvd "] +license = "MIT" +readme = "README.md" +packages = [{include = "sikepuri_of_algorithm"}] + +[tool.poetry.dependencies] +python = "^3.10" + + +[build-system] +requires = ["poetry-core"] +build-backend = "poetry.core.masonry.api" From 59075a540f20e943312e224bc865066deab88e2a Mon Sep 17 00:00:00 2001 From: chvmvd Date: Sat, 10 Dec 2022 21:54:49 +0900 Subject: [PATCH 07/20] Add poetry.lock --- poetry.lock | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 poetry.lock diff --git a/poetry.lock b/poetry.lock new file mode 100644 index 000000000..be2d2fcaf --- /dev/null +++ b/poetry.lock @@ -0,0 +1,7 @@ +# This file is automatically @generated by Poetry and should not be changed by hand. +package = [] + +[metadata] +lock-version = "2.0" +python-versions = "^3.10" +content-hash = "53f2eabc9c26446fbcc00d348c47878e118afc2054778c3c803a0a8028af27d9" From 8a54422d090c21ea6254f4413dff28e12166f643 Mon Sep 17 00:00:00 2001 From: chvmvd Date: Sat, 10 Dec 2022 21:58:48 +0900 Subject: [PATCH 08/20] Introduce pre-commit --- poetry.lock | 209 ++++++++++++++++++++++++++++++++++++++++++++++++- pyproject.toml | 1 + 2 files changed, 208 insertions(+), 2 deletions(-) diff --git a/poetry.lock b/poetry.lock index be2d2fcaf..352cdf663 100644 --- a/poetry.lock +++ b/poetry.lock @@ -1,7 +1,212 @@ # This file is automatically @generated by Poetry and should not be changed by hand. -package = [] + +[[package]] +name = "cfgv" +version = "3.3.1" +description = "Validate configuration and produce human readable error messages." +category = "main" +optional = false +python-versions = ">=3.6.1" +files = [ + {file = "cfgv-3.3.1-py2.py3-none-any.whl", hash = "sha256:c6a0883f3917a037485059700b9e75da2464e6c27051014ad85ba6aaa5884426"}, + {file = "cfgv-3.3.1.tar.gz", hash = "sha256:f5a830efb9ce7a445376bb66ec94c638a9787422f96264c98edc6bdeed8ab736"}, +] + +[[package]] +name = "distlib" +version = "0.3.6" +description = "Distribution utilities" +category = "main" +optional = false +python-versions = "*" +files = [ + {file = "distlib-0.3.6-py2.py3-none-any.whl", hash = "sha256:f35c4b692542ca110de7ef0bea44d73981caeb34ca0b9b6b2e6d7790dda8f80e"}, + {file = "distlib-0.3.6.tar.gz", hash = "sha256:14bad2d9b04d3a36127ac97f30b12a19268f211063d8f8ee4f47108896e11b46"}, +] + +[[package]] +name = "filelock" +version = "3.8.2" +description = "A platform independent file lock." +category = "main" +optional = false +python-versions = ">=3.7" +files = [ + {file = "filelock-3.8.2-py3-none-any.whl", hash = "sha256:8df285554452285f79c035efb0c861eb33a4bcfa5b7a137016e32e6a90f9792c"}, + {file = "filelock-3.8.2.tar.gz", hash = "sha256:7565f628ea56bfcd8e54e42bdc55da899c85c1abfe1b5bcfd147e9188cebb3b2"}, +] + +[package.extras] +docs = ["furo (>=2022.9.29)", "sphinx (>=5.3)", "sphinx-autodoc-typehints (>=1.19.5)"] +testing = ["covdefaults (>=2.2.2)", "coverage (>=6.5)", "pytest (>=7.2)", "pytest-cov (>=4)", "pytest-timeout (>=2.1)"] + +[[package]] +name = "identify" +version = "2.5.9" +description = "File identification library for Python" +category = "main" +optional = false +python-versions = ">=3.7" +files = [ + {file = "identify-2.5.9-py2.py3-none-any.whl", hash = "sha256:a390fb696e164dbddb047a0db26e57972ae52fbd037ae68797e5ae2f4492485d"}, + {file = "identify-2.5.9.tar.gz", hash = "sha256:906036344ca769539610436e40a684e170c3648b552194980bb7b617a8daeb9f"}, +] + +[package.extras] +license = ["ukkonen"] + +[[package]] +name = "nodeenv" +version = "1.7.0" +description = "Node.js virtual environment builder" +category = "main" +optional = false +python-versions = ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*" +files = [ + {file = "nodeenv-1.7.0-py2.py3-none-any.whl", hash = "sha256:27083a7b96a25f2f5e1d8cb4b6317ee8aeda3bdd121394e5ac54e498028a042e"}, + {file = "nodeenv-1.7.0.tar.gz", hash = "sha256:e0e7f7dfb85fc5394c6fe1e8fa98131a2473e04311a45afb6508f7cf1836fa2b"}, +] + +[package.dependencies] +setuptools = "*" + +[[package]] +name = "platformdirs" +version = "2.6.0" +description = "A small Python package for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." +category = "main" +optional = false +python-versions = ">=3.7" +files = [ + {file = "platformdirs-2.6.0-py3-none-any.whl", hash = "sha256:1a89a12377800c81983db6be069ec068eee989748799b946cce2a6e80dcc54ca"}, + {file = "platformdirs-2.6.0.tar.gz", hash = "sha256:b46ffafa316e6b83b47489d240ce17173f123a9b9c83282141c3daf26ad9ac2e"}, +] + +[package.extras] +docs = ["furo (>=2022.9.29)", "proselint (>=0.13)", "sphinx (>=5.3)", "sphinx-autodoc-typehints (>=1.19.4)"] +test = ["appdirs (==1.4.4)", "pytest (>=7.2)", "pytest-cov (>=4)", "pytest-mock (>=3.10)"] + +[[package]] +name = "pre-commit" +version = "2.20.0" +description = "A framework for managing and maintaining multi-language pre-commit hooks." +category = "main" +optional = false +python-versions = ">=3.7" +files = [ + {file = "pre_commit-2.20.0-py2.py3-none-any.whl", hash = "sha256:51a5ba7c480ae8072ecdb6933df22d2f812dc897d5fe848778116129a681aac7"}, + {file = "pre_commit-2.20.0.tar.gz", hash = "sha256:a978dac7bc9ec0bcee55c18a277d553b0f419d259dadb4b9418ff2d00eb43959"}, +] + +[package.dependencies] +cfgv = ">=2.0.0" +identify = ">=1.0.0" +nodeenv = ">=0.11.1" +pyyaml = ">=5.1" +toml = "*" +virtualenv = ">=20.0.8" + +[[package]] +name = "pyyaml" +version = "6.0" +description = "YAML parser and emitter for Python" +category = "main" +optional = false +python-versions = ">=3.6" +files = [ + {file = "PyYAML-6.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53"}, + {file = "PyYAML-6.0-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c"}, + {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc"}, + {file = "PyYAML-6.0-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:a80a78046a72361de73f8f395f1f1e49f956c6be882eed58505a15f3e430962b"}, + {file = "PyYAML-6.0-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5"}, + {file = "PyYAML-6.0-cp310-cp310-win32.whl", hash = "sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513"}, + {file = "PyYAML-6.0-cp310-cp310-win_amd64.whl", hash = "sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:d4b0ba9512519522b118090257be113b9468d804b19d63c71dbcf4a48fa32358"}, + {file = "PyYAML-6.0-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:81957921f441d50af23654aa6c5e5eaf9b06aba7f0a19c18a538dc7ef291c5a1"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:afa17f5bc4d1b10afd4466fd3a44dc0e245382deca5b3c353d8b757f9e3ecb8d"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:dbad0e9d368bb989f4515da330b88a057617d16b6a8245084f1b05400f24609f"}, + {file = "PyYAML-6.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:432557aa2c09802be39460360ddffd48156e30721f5e8d917f01d31694216782"}, + {file = "PyYAML-6.0-cp311-cp311-win32.whl", hash = "sha256:bfaef573a63ba8923503d27530362590ff4f576c626d86a9fed95822a8255fd7"}, + {file = "PyYAML-6.0-cp311-cp311-win_amd64.whl", hash = "sha256:01b45c0191e6d66c470b6cf1b9531a771a83c1c4208272ead47a3ae4f2f603bf"}, + {file = "PyYAML-6.0-cp36-cp36m-macosx_10_9_x86_64.whl", hash = "sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86"}, + {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f"}, + {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92"}, + {file = "PyYAML-6.0-cp36-cp36m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:98c4d36e99714e55cfbaaee6dd5badbc9a1ec339ebfc3b1f52e293aee6bb71a4"}, + {file = "PyYAML-6.0-cp36-cp36m-win32.whl", hash = "sha256:0283c35a6a9fbf047493e3a0ce8d79ef5030852c51e9d911a27badfde0605293"}, + {file = "PyYAML-6.0-cp36-cp36m-win_amd64.whl", hash = "sha256:07751360502caac1c067a8132d150cf3d61339af5691fe9e87803040dbc5db57"}, + {file = "PyYAML-6.0-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:819b3830a1543db06c4d4b865e70ded25be52a2e0631ccd2f6a47a2822f2fd7c"}, + {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:473f9edb243cb1935ab5a084eb238d842fb8f404ed2193a915d1784b5a6b5fc0"}, + {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:0ce82d761c532fe4ec3f87fc45688bdd3a4c1dc5e0b4a19814b9009a29baefd4"}, + {file = "PyYAML-6.0-cp37-cp37m-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:231710d57adfd809ef5d34183b8ed1eeae3f76459c18fb4a0b373ad56bedcdd9"}, + {file = "PyYAML-6.0-cp37-cp37m-win32.whl", hash = "sha256:c5687b8d43cf58545ade1fe3e055f70eac7a5a1a0bf42824308d868289a95737"}, + {file = "PyYAML-6.0-cp37-cp37m-win_amd64.whl", hash = "sha256:d15a181d1ecd0d4270dc32edb46f7cb7733c7c508857278d3d378d14d606db2d"}, + {file = "PyYAML-6.0-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:0b4624f379dab24d3725ffde76559cff63d9ec94e1736b556dacdfebe5ab6d4b"}, + {file = "PyYAML-6.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:213c60cd50106436cc818accf5baa1aba61c0189ff610f64f4a3e8c6726218ba"}, + {file = "PyYAML-6.0-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:9fa600030013c4de8165339db93d182b9431076eb98eb40ee068700c9c813e34"}, + {file = "PyYAML-6.0-cp38-cp38-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:277a0ef2981ca40581a47093e9e2d13b3f1fbbeffae064c1d21bfceba2030287"}, + {file = "PyYAML-6.0-cp38-cp38-win32.whl", hash = "sha256:d4eccecf9adf6fbcc6861a38015c2a64f38b9d94838ac1810a9023a0609e1b78"}, + {file = "PyYAML-6.0-cp38-cp38-win_amd64.whl", hash = "sha256:1e4747bc279b4f613a09eb64bba2ba602d8a6664c6ce6396a4d0cd413a50ce07"}, + {file = "PyYAML-6.0-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:055d937d65826939cb044fc8c9b08889e8c743fdc6a32b33e2390f66013e449b"}, + {file = "PyYAML-6.0-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:e61ceaab6f49fb8bdfaa0f92c4b57bcfbea54c09277b1b4f7ac376bfb7a7c174"}, + {file = "PyYAML-6.0-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d67d839ede4ed1b28a4e8909735fc992a923cdb84e618544973d7dfc71540803"}, + {file = "PyYAML-6.0-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:cba8c411ef271aa037d7357a2bc8f9ee8b58b9965831d9e51baf703280dc73d3"}, + {file = "PyYAML-6.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl", hash = "sha256:40527857252b61eacd1d9af500c3337ba8deb8fc298940291486c465c8b46ec0"}, + {file = "PyYAML-6.0-cp39-cp39-win32.whl", hash = "sha256:b5b9eccad747aabaaffbc6064800670f0c297e52c12754eb1d976c57e4f74dcb"}, + {file = "PyYAML-6.0-cp39-cp39-win_amd64.whl", hash = "sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c"}, + {file = "PyYAML-6.0.tar.gz", hash = "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2"}, +] + +[[package]] +name = "setuptools" +version = "65.6.3" +description = "Easily download, build, install, upgrade, and uninstall Python packages" +category = "main" +optional = false +python-versions = ">=3.7" +files = [ + {file = "setuptools-65.6.3-py3-none-any.whl", hash = "sha256:57f6f22bde4e042978bcd50176fdb381d7c21a9efa4041202288d3737a0c6a54"}, + {file = "setuptools-65.6.3.tar.gz", hash = "sha256:a7620757bf984b58deaf32fc8a4577a9bbc0850cf92c20e1ce41c38c19e5fb75"}, +] + +[package.extras] +docs = ["furo", "jaraco.packaging (>=9)", "jaraco.tidelift (>=1.4)", "pygments-github-lexers (==0.0.5)", "rst.linker (>=1.9)", "sphinx (>=3.5)", "sphinx-favicon", "sphinx-hoverxref (<2)", "sphinx-inline-tabs", "sphinx-notfound-page (==0.8.3)", "sphinx-reredirects", "sphinxcontrib-towncrier"] +testing = ["build[virtualenv]", "filelock (>=3.4.0)", "flake8 (<5)", "flake8-2020", "ini2toml[lite] (>=0.9)", "jaraco.envs (>=2.2)", "jaraco.path (>=3.2.0)", "pip (>=19.1)", "pip-run (>=8.8)", "pytest (>=6)", "pytest-black (>=0.3.7)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-flake8", "pytest-mypy (>=0.9.1)", "pytest-perf", "pytest-timeout", "pytest-xdist", "tomli-w (>=1.0.0)", "virtualenv (>=13.0.0)", "wheel"] +testing-integration = ["build[virtualenv]", "filelock (>=3.4.0)", "jaraco.envs (>=2.2)", "jaraco.path (>=3.2.0)", "pytest", "pytest-enabler", "pytest-xdist", "tomli", "virtualenv (>=13.0.0)", "wheel"] + +[[package]] +name = "toml" +version = "0.10.2" +description = "Python Library for Tom's Obvious, Minimal Language" +category = "main" +optional = false +python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*" +files = [ + {file = "toml-0.10.2-py2.py3-none-any.whl", hash = "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b"}, + {file = "toml-0.10.2.tar.gz", hash = "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f"}, +] + +[[package]] +name = "virtualenv" +version = "20.17.1" +description = "Virtual Python Environment builder" +category = "main" +optional = false +python-versions = ">=3.6" +files = [ + {file = "virtualenv-20.17.1-py3-none-any.whl", hash = "sha256:ce3b1684d6e1a20a3e5ed36795a97dfc6af29bc3970ca8dab93e11ac6094b3c4"}, + {file = "virtualenv-20.17.1.tar.gz", hash = "sha256:f8b927684efc6f1cc206c9db297a570ab9ad0e51c16fa9e45487d36d1905c058"}, +] + +[package.dependencies] +distlib = ">=0.3.6,<1" +filelock = ">=3.4.1,<4" +platformdirs = ">=2.4,<3" + +[package.extras] +docs = ["proselint (>=0.13)", "sphinx (>=5.3)", "sphinx-argparse (>=0.3.2)", "sphinx-rtd-theme (>=1)", "towncrier (>=22.8)"] +testing = ["coverage (>=6.2)", "coverage-enable-subprocess (>=1)", "flaky (>=3.7)", "packaging (>=21.3)", "pytest (>=7.0.1)", "pytest-env (>=0.6.2)", "pytest-freezegun (>=0.4.2)", "pytest-mock (>=3.6.1)", "pytest-randomly (>=3.10.3)", "pytest-timeout (>=2.1)"] [metadata] lock-version = "2.0" python-versions = "^3.10" -content-hash = "53f2eabc9c26446fbcc00d348c47878e118afc2054778c3c803a0a8028af27d9" +content-hash = "a30997f7596d98791c676d3fddaf490a15fe0165d7e41d3ec39a74fb4696eeb0" diff --git a/pyproject.toml b/pyproject.toml index f384eca78..5bb5fc9e4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -9,6 +9,7 @@ packages = [{include = "sikepuri_of_algorithm"}] [tool.poetry.dependencies] python = "^3.10" +pre-commit = "^2.20.0" [build-system] From e87f70143023766d792e3aa7622f4acc7195e24d Mon Sep 17 00:00:00 2001 From: chvmvd Date: Sat, 10 Dec 2022 22:02:39 +0900 Subject: [PATCH 09/20] Update README.md --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index ba4976794..6107c35e0 100644 --- a/README.md +++ b/README.md @@ -17,15 +17,15 @@ npm ci ไปฅไธ‹ใฏใ€ใ‚ณใƒŸใƒƒใƒˆๆ™‚ใซ่‡ชๅ‹•ใง Formatter ใ‚„ Linter ใ‚’ๅฎŸ่กŒใ•ใ›ใ‚‹ใŸใ‚ใฎใ‚นใ‚ฏใƒชใƒ—ใƒˆใงใ™ใ€‚ๅฎŸ่กŒใ—ใชใใฆใ‚‚ๆง‹ใ„ใพใ›ใ‚“ใ€‚ ```shell -pip install pipenv +curl -sSL https://install.python-poetry.org | python3 - ``` ```shell -pipenv sync --dev +poetry install ``` ```shell -pipenv run pre-commit install +poetry run pre-commit install ``` ## ้–‹็™บ From d6e3a881665d5c4440dd108094408d1e886cd417 Mon Sep 17 00:00:00 2001 From: chvmvd Date: Sat, 10 Dec 2022 22:03:41 +0900 Subject: [PATCH 10/20] Remove pipenv --- Pipfile | 13 --- Pipfile.lock | 265 --------------------------------------------------- 2 files changed, 278 deletions(-) delete mode 100644 Pipfile delete mode 100644 Pipfile.lock diff --git a/Pipfile b/Pipfile deleted file mode 100644 index 01848548b..000000000 --- a/Pipfile +++ /dev/null @@ -1,13 +0,0 @@ -[[source]] -url = "https://pypi.org/simple" -verify_ssl = true -name = "pypi" - -[packages] - -[dev-packages] -pre-commit = "*" - -[requires] -python_version = "3.10" -python_full_version = "3.10.6" diff --git a/Pipfile.lock b/Pipfile.lock deleted file mode 100644 index 3f1d3faa7..000000000 --- a/Pipfile.lock +++ /dev/null @@ -1,265 +0,0 @@ -{ - "_meta": { - "hash": { - "sha256": "0965ffc7cf09a86bc95fee6b738f9a6107c8fe8e1a8fa50e0339e09635f9a5e6" - }, - "pipfile-spec": 6, - "requires": { - "python_full_version": "3.10.6", - "python_version": "3.10" - }, - "sources": [ - { - "name": "pypi", - "url": "https://pypi.org/simple", - "verify_ssl": true - } - ] - }, - "default": { - "cfgv": { - "hashes": [ - "sha256:c6a0883f3917a037485059700b9e75da2464e6c27051014ad85ba6aaa5884426", - "sha256:f5a830efb9ce7a445376bb66ec94c638a9787422f96264c98edc6bdeed8ab736" - ], - "markers": "python_full_version >= '3.6.1'", - "version": "==3.3.1" - }, - "distlib": { - "hashes": [ - "sha256:14bad2d9b04d3a36127ac97f30b12a19268f211063d8f8ee4f47108896e11b46", - "sha256:f35c4b692542ca110de7ef0bea44d73981caeb34ca0b9b6b2e6d7790dda8f80e" - ], - "version": "==0.3.6" - }, - "filelock": { - "hashes": [ - "sha256:55447caa666f2198c5b6b13a26d2084d26fa5b115c00d065664b2124680c4edc", - "sha256:617eb4e5eedc82fc5f47b6d61e4d11cb837c56cb4544e39081099fa17ad109d4" - ], - "markers": "python_version >= '3.7'", - "version": "==3.8.0" - }, - "identify": { - "hashes": [ - "sha256:6c32dbd747aa4ceee1df33f25fed0b0f6e0d65721b15bd151307ff7056d50245", - "sha256:b276db7ec52d7e89f5bc4653380e33054ddc803d25875952ad90b0f012cbcdaa" - ], - "markers": "python_version >= '3.7'", - "version": "==2.5.6" - }, - "nodeenv": { - "hashes": [ - "sha256:27083a7b96a25f2f5e1d8cb4b6317ee8aeda3bdd121394e5ac54e498028a042e", - "sha256:e0e7f7dfb85fc5394c6fe1e8fa98131a2473e04311a45afb6508f7cf1836fa2b" - ], - "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5, 3.6'", - "version": "==1.7.0" - }, - "platformdirs": { - "hashes": [ - "sha256:027d8e83a2d7de06bbac4e5ef7e023c02b863d7ea5d079477e722bb41ab25788", - "sha256:58c8abb07dcb441e6ee4b11d8df0ac856038f944ab98b7be6b27b2a3c7feef19" - ], - "markers": "python_version >= '3.7'", - "version": "==2.5.2" - }, - "pyyaml": { - "hashes": [ - "sha256:01b45c0191e6d66c470b6cf1b9531a771a83c1c4208272ead47a3ae4f2f603bf", - "sha256:0283c35a6a9fbf047493e3a0ce8d79ef5030852c51e9d911a27badfde0605293", - "sha256:055d937d65826939cb044fc8c9b08889e8c743fdc6a32b33e2390f66013e449b", - "sha256:07751360502caac1c067a8132d150cf3d61339af5691fe9e87803040dbc5db57", - "sha256:0b4624f379dab24d3725ffde76559cff63d9ec94e1736b556dacdfebe5ab6d4b", - "sha256:0ce82d761c532fe4ec3f87fc45688bdd3a4c1dc5e0b4a19814b9009a29baefd4", - "sha256:1e4747bc279b4f613a09eb64bba2ba602d8a6664c6ce6396a4d0cd413a50ce07", - "sha256:213c60cd50106436cc818accf5baa1aba61c0189ff610f64f4a3e8c6726218ba", - "sha256:231710d57adfd809ef5d34183b8ed1eeae3f76459c18fb4a0b373ad56bedcdd9", - "sha256:277a0ef2981ca40581a47093e9e2d13b3f1fbbeffae064c1d21bfceba2030287", - "sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513", - "sha256:40527857252b61eacd1d9af500c3337ba8deb8fc298940291486c465c8b46ec0", - "sha256:432557aa2c09802be39460360ddffd48156e30721f5e8d917f01d31694216782", - "sha256:473f9edb243cb1935ab5a084eb238d842fb8f404ed2193a915d1784b5a6b5fc0", - "sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92", - "sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f", - "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2", - "sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc", - "sha256:81957921f441d50af23654aa6c5e5eaf9b06aba7f0a19c18a538dc7ef291c5a1", - "sha256:819b3830a1543db06c4d4b865e70ded25be52a2e0631ccd2f6a47a2822f2fd7c", - "sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86", - "sha256:98c4d36e99714e55cfbaaee6dd5badbc9a1ec339ebfc3b1f52e293aee6bb71a4", - "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c", - "sha256:9fa600030013c4de8165339db93d182b9431076eb98eb40ee068700c9c813e34", - "sha256:a80a78046a72361de73f8f395f1f1e49f956c6be882eed58505a15f3e430962b", - "sha256:afa17f5bc4d1b10afd4466fd3a44dc0e245382deca5b3c353d8b757f9e3ecb8d", - "sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c", - "sha256:b5b9eccad747aabaaffbc6064800670f0c297e52c12754eb1d976c57e4f74dcb", - "sha256:bfaef573a63ba8923503d27530362590ff4f576c626d86a9fed95822a8255fd7", - "sha256:c5687b8d43cf58545ade1fe3e055f70eac7a5a1a0bf42824308d868289a95737", - "sha256:cba8c411ef271aa037d7357a2bc8f9ee8b58b9965831d9e51baf703280dc73d3", - "sha256:d15a181d1ecd0d4270dc32edb46f7cb7733c7c508857278d3d378d14d606db2d", - "sha256:d4b0ba9512519522b118090257be113b9468d804b19d63c71dbcf4a48fa32358", - "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53", - "sha256:d4eccecf9adf6fbcc6861a38015c2a64f38b9d94838ac1810a9023a0609e1b78", - "sha256:d67d839ede4ed1b28a4e8909735fc992a923cdb84e618544973d7dfc71540803", - "sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a", - "sha256:dbad0e9d368bb989f4515da330b88a057617d16b6a8245084f1b05400f24609f", - "sha256:e61ceaab6f49fb8bdfaa0f92c4b57bcfbea54c09277b1b4f7ac376bfb7a7c174", - "sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5" - ], - "markers": "python_version >= '3.6'", - "version": "==6.0" - }, - "setuptools": { - "hashes": [ - "sha256:512e5536220e38146176efb833d4a62aa726b7bbff82cfbc8ba9eaa3996e0b17", - "sha256:f62ea9da9ed6289bfe868cd6845968a2c854d1427f8548d52cae02a42b4f0356" - ], - "markers": "python_version >= '3.7'", - "version": "==65.5.0" - }, - "toml": { - "hashes": [ - "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b", - "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f" - ], - "markers": "python_version >= '2.6' and python_version not in '3.0, 3.1, 3.2'", - "version": "==0.10.2" - }, - "virtualenv": { - "hashes": [ - "sha256:227ea1b9994fdc5ea31977ba3383ef296d7472ea85be9d6732e42a91c04e80da", - "sha256:d07dfc5df5e4e0dbc92862350ad87a36ed505b978f6c39609dc489eadd5b0d27" - ], - "markers": "python_version >= '3.6'", - "version": "==20.16.5" - } - }, - "develop": { - "cfgv": { - "hashes": [ - "sha256:c6a0883f3917a037485059700b9e75da2464e6c27051014ad85ba6aaa5884426", - "sha256:f5a830efb9ce7a445376bb66ec94c638a9787422f96264c98edc6bdeed8ab736" - ], - "markers": "python_full_version >= '3.6.1'", - "version": "==3.3.1" - }, - "distlib": { - "hashes": [ - "sha256:14bad2d9b04d3a36127ac97f30b12a19268f211063d8f8ee4f47108896e11b46", - "sha256:f35c4b692542ca110de7ef0bea44d73981caeb34ca0b9b6b2e6d7790dda8f80e" - ], - "version": "==0.3.6" - }, - "filelock": { - "hashes": [ - "sha256:55447caa666f2198c5b6b13a26d2084d26fa5b115c00d065664b2124680c4edc", - "sha256:617eb4e5eedc82fc5f47b6d61e4d11cb837c56cb4544e39081099fa17ad109d4" - ], - "markers": "python_version >= '3.7'", - "version": "==3.8.0" - }, - "identify": { - "hashes": [ - "sha256:6c32dbd747aa4ceee1df33f25fed0b0f6e0d65721b15bd151307ff7056d50245", - "sha256:b276db7ec52d7e89f5bc4653380e33054ddc803d25875952ad90b0f012cbcdaa" - ], - "markers": "python_version >= '3.7'", - "version": "==2.5.6" - }, - "nodeenv": { - "hashes": [ - "sha256:27083a7b96a25f2f5e1d8cb4b6317ee8aeda3bdd121394e5ac54e498028a042e", - "sha256:e0e7f7dfb85fc5394c6fe1e8fa98131a2473e04311a45afb6508f7cf1836fa2b" - ], - "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5, 3.6'", - "version": "==1.7.0" - }, - "platformdirs": { - "hashes": [ - "sha256:027d8e83a2d7de06bbac4e5ef7e023c02b863d7ea5d079477e722bb41ab25788", - "sha256:58c8abb07dcb441e6ee4b11d8df0ac856038f944ab98b7be6b27b2a3c7feef19" - ], - "markers": "python_version >= '3.7'", - "version": "==2.5.2" - }, - "pre-commit": { - "hashes": [ - "sha256:51a5ba7c480ae8072ecdb6933df22d2f812dc897d5fe848778116129a681aac7", - "sha256:a978dac7bc9ec0bcee55c18a277d553b0f419d259dadb4b9418ff2d00eb43959" - ], - "index": "pypi", - "version": "==2.20.0" - }, - "pyyaml": { - "hashes": [ - "sha256:01b45c0191e6d66c470b6cf1b9531a771a83c1c4208272ead47a3ae4f2f603bf", - "sha256:0283c35a6a9fbf047493e3a0ce8d79ef5030852c51e9d911a27badfde0605293", - "sha256:055d937d65826939cb044fc8c9b08889e8c743fdc6a32b33e2390f66013e449b", - "sha256:07751360502caac1c067a8132d150cf3d61339af5691fe9e87803040dbc5db57", - "sha256:0b4624f379dab24d3725ffde76559cff63d9ec94e1736b556dacdfebe5ab6d4b", - "sha256:0ce82d761c532fe4ec3f87fc45688bdd3a4c1dc5e0b4a19814b9009a29baefd4", - "sha256:1e4747bc279b4f613a09eb64bba2ba602d8a6664c6ce6396a4d0cd413a50ce07", - "sha256:213c60cd50106436cc818accf5baa1aba61c0189ff610f64f4a3e8c6726218ba", - "sha256:231710d57adfd809ef5d34183b8ed1eeae3f76459c18fb4a0b373ad56bedcdd9", - "sha256:277a0ef2981ca40581a47093e9e2d13b3f1fbbeffae064c1d21bfceba2030287", - "sha256:2cd5df3de48857ed0544b34e2d40e9fac445930039f3cfe4bcc592a1f836d513", - "sha256:40527857252b61eacd1d9af500c3337ba8deb8fc298940291486c465c8b46ec0", - "sha256:432557aa2c09802be39460360ddffd48156e30721f5e8d917f01d31694216782", - "sha256:473f9edb243cb1935ab5a084eb238d842fb8f404ed2193a915d1784b5a6b5fc0", - "sha256:48c346915c114f5fdb3ead70312bd042a953a8ce5c7106d5bfb1a5254e47da92", - "sha256:50602afada6d6cbfad699b0c7bb50d5ccffa7e46a3d738092afddc1f9758427f", - "sha256:68fb519c14306fec9720a2a5b45bc9f0c8d1b9c72adf45c37baedfcd949c35a2", - "sha256:77f396e6ef4c73fdc33a9157446466f1cff553d979bd00ecb64385760c6babdc", - "sha256:81957921f441d50af23654aa6c5e5eaf9b06aba7f0a19c18a538dc7ef291c5a1", - "sha256:819b3830a1543db06c4d4b865e70ded25be52a2e0631ccd2f6a47a2822f2fd7c", - "sha256:897b80890765f037df3403d22bab41627ca8811ae55e9a722fd0392850ec4d86", - "sha256:98c4d36e99714e55cfbaaee6dd5badbc9a1ec339ebfc3b1f52e293aee6bb71a4", - "sha256:9df7ed3b3d2e0ecfe09e14741b857df43adb5a3ddadc919a2d94fbdf78fea53c", - "sha256:9fa600030013c4de8165339db93d182b9431076eb98eb40ee068700c9c813e34", - "sha256:a80a78046a72361de73f8f395f1f1e49f956c6be882eed58505a15f3e430962b", - "sha256:afa17f5bc4d1b10afd4466fd3a44dc0e245382deca5b3c353d8b757f9e3ecb8d", - "sha256:b3d267842bf12586ba6c734f89d1f5b871df0273157918b0ccefa29deb05c21c", - "sha256:b5b9eccad747aabaaffbc6064800670f0c297e52c12754eb1d976c57e4f74dcb", - "sha256:bfaef573a63ba8923503d27530362590ff4f576c626d86a9fed95822a8255fd7", - "sha256:c5687b8d43cf58545ade1fe3e055f70eac7a5a1a0bf42824308d868289a95737", - "sha256:cba8c411ef271aa037d7357a2bc8f9ee8b58b9965831d9e51baf703280dc73d3", - "sha256:d15a181d1ecd0d4270dc32edb46f7cb7733c7c508857278d3d378d14d606db2d", - "sha256:d4b0ba9512519522b118090257be113b9468d804b19d63c71dbcf4a48fa32358", - "sha256:d4db7c7aef085872ef65a8fd7d6d09a14ae91f691dec3e87ee5ee0539d516f53", - "sha256:d4eccecf9adf6fbcc6861a38015c2a64f38b9d94838ac1810a9023a0609e1b78", - "sha256:d67d839ede4ed1b28a4e8909735fc992a923cdb84e618544973d7dfc71540803", - "sha256:daf496c58a8c52083df09b80c860005194014c3698698d1a57cbcfa182142a3a", - "sha256:dbad0e9d368bb989f4515da330b88a057617d16b6a8245084f1b05400f24609f", - "sha256:e61ceaab6f49fb8bdfaa0f92c4b57bcfbea54c09277b1b4f7ac376bfb7a7c174", - "sha256:f84fbc98b019fef2ee9a1cb3ce93e3187a6df0b2538a651bfb890254ba9f90b5" - ], - "markers": "python_version >= '3.6'", - "version": "==6.0" - }, - "setuptools": { - "hashes": [ - "sha256:512e5536220e38146176efb833d4a62aa726b7bbff82cfbc8ba9eaa3996e0b17", - "sha256:f62ea9da9ed6289bfe868cd6845968a2c854d1427f8548d52cae02a42b4f0356" - ], - "markers": "python_version >= '3.7'", - "version": "==65.5.0" - }, - "toml": { - "hashes": [ - "sha256:806143ae5bfb6a3c6e736a764057db0e6a0e05e338b5630894a5f779cabb4f9b", - "sha256:b3bda1d108d5dd99f4a20d24d9c348e91c4db7ab1b749200bded2f839ccbe68f" - ], - "markers": "python_version >= '2.6' and python_version not in '3.0, 3.1, 3.2'", - "version": "==0.10.2" - }, - "virtualenv": { - "hashes": [ - "sha256:227ea1b9994fdc5ea31977ba3383ef296d7472ea85be9d6732e42a91c04e80da", - "sha256:d07dfc5df5e4e0dbc92862350ad87a36ed505b978f6c39609dc489eadd5b0d27" - ], - "markers": "python_version >= '3.6'", - "version": "==20.16.5" - } - } -} From 8a74dbd5af24f00fd891c810366c55bb880fc6b9 Mon Sep 17 00:00:00 2001 From: chvmvd Date: Sat, 10 Dec 2022 22:09:11 +0900 Subject: [PATCH 11/20] Reinstall pre-commit as dev --- poetry.lock | 24 ++++++++++++------------ pyproject.toml | 4 +++- 2 files changed, 15 insertions(+), 13 deletions(-) diff --git a/poetry.lock b/poetry.lock index 352cdf663..76084a07f 100644 --- a/poetry.lock +++ b/poetry.lock @@ -4,7 +4,7 @@ name = "cfgv" version = "3.3.1" description = "Validate configuration and produce human readable error messages." -category = "main" +category = "dev" optional = false python-versions = ">=3.6.1" files = [ @@ -16,7 +16,7 @@ files = [ name = "distlib" version = "0.3.6" description = "Distribution utilities" -category = "main" +category = "dev" optional = false python-versions = "*" files = [ @@ -28,7 +28,7 @@ files = [ name = "filelock" version = "3.8.2" description = "A platform independent file lock." -category = "main" +category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -44,7 +44,7 @@ testing = ["covdefaults (>=2.2.2)", "coverage (>=6.5)", "pytest (>=7.2)", "pytes name = "identify" version = "2.5.9" description = "File identification library for Python" -category = "main" +category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -59,7 +59,7 @@ license = ["ukkonen"] name = "nodeenv" version = "1.7.0" description = "Node.js virtual environment builder" -category = "main" +category = "dev" optional = false python-versions = ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*" files = [ @@ -74,7 +74,7 @@ setuptools = "*" name = "platformdirs" version = "2.6.0" description = "A small Python package for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." -category = "main" +category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -90,7 +90,7 @@ test = ["appdirs (==1.4.4)", "pytest (>=7.2)", "pytest-cov (>=4)", "pytest-mock name = "pre-commit" version = "2.20.0" description = "A framework for managing and maintaining multi-language pre-commit hooks." -category = "main" +category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -110,7 +110,7 @@ virtualenv = ">=20.0.8" name = "pyyaml" version = "6.0" description = "YAML parser and emitter for Python" -category = "main" +category = "dev" optional = false python-versions = ">=3.6" files = [ @@ -160,7 +160,7 @@ files = [ name = "setuptools" version = "65.6.3" description = "Easily download, build, install, upgrade, and uninstall Python packages" -category = "main" +category = "dev" optional = false python-versions = ">=3.7" files = [ @@ -177,7 +177,7 @@ testing-integration = ["build[virtualenv]", "filelock (>=3.4.0)", "jaraco.envs ( name = "toml" version = "0.10.2" description = "Python Library for Tom's Obvious, Minimal Language" -category = "main" +category = "dev" optional = false python-versions = ">=2.6, !=3.0.*, !=3.1.*, !=3.2.*" files = [ @@ -189,7 +189,7 @@ files = [ name = "virtualenv" version = "20.17.1" description = "Virtual Python Environment builder" -category = "main" +category = "dev" optional = false python-versions = ">=3.6" files = [ @@ -209,4 +209,4 @@ testing = ["coverage (>=6.2)", "coverage-enable-subprocess (>=1)", "flaky (>=3.7 [metadata] lock-version = "2.0" python-versions = "^3.10" -content-hash = "a30997f7596d98791c676d3fddaf490a15fe0165d7e41d3ec39a74fb4696eeb0" +content-hash = "0ea2333e0d368f9c74bc3ad3c35c5c09a6ae4296a4661b5ff222eab2e37e0650" diff --git a/pyproject.toml b/pyproject.toml index 5bb5fc9e4..98756fb9d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -9,9 +9,11 @@ packages = [{include = "sikepuri_of_algorithm"}] [tool.poetry.dependencies] python = "^3.10" -pre-commit = "^2.20.0" +[tool.poetry.group.dev.dependencies] +pre-commit = "^2.20.0" + [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" From 4be0658120e4a88593e1bee0deffa5ad2fdc1dca Mon Sep 17 00:00:00 2001 From: chvmvd Date: Sat, 10 Dec 2022 22:14:34 +0900 Subject: [PATCH 12/20] Add exclude files --- pyproject.toml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pyproject.toml b/pyproject.toml index 98756fb9d..faa51c132 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -17,3 +17,6 @@ pre-commit = "^2.20.0" [build-system] requires = ["poetry-core"] build-backend = "poetry.core.masonry.api" + +[tool.black] +exclude=".*sum_1to100.ipynb" From 8ca9e3a8deeab461196c9139578319ddd9ef88de Mon Sep 17 00:00:00 2001 From: chvmvd Date: Sat, 10 Dec 2022 22:39:34 +0900 Subject: [PATCH 13/20] Remove deprecated exclude --- .github/workflows/black.yml | 1 - .pre-commit-config.yaml | 1 - 2 files changed, 2 deletions(-) diff --git a/.github/workflows/black.yml b/.github/workflows/black.yml index 7aa3895bd..0d3cc12a0 100644 --- a/.github/workflows/black.yml +++ b/.github/workflows/black.yml @@ -17,5 +17,4 @@ jobs: - name: Run Black uses: psf/black@stable with: - options: '--exclude="docs/01python/07for/_samples/sum_1to100.ipynb"' jupyter: true diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index cb782970a..50066fef2 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -15,7 +15,6 @@ repos: hooks: - id: black - id: black-jupyter - exclude: .*sum_1to100.ipynb - repo: https://github.com/pre-commit/mirrors-eslint rev: v8.26.0 hooks: From 02958eca12c6c8e91b2bde510f073976c95cf6fe Mon Sep 17 00:00:00 2001 From: chvmvd Date: Sat, 10 Dec 2022 22:51:12 +0900 Subject: [PATCH 14/20] Update ESLint GitHub Actions --- .github/workflows/eslint.yml | 31 +++++++++++++++++++++++++++++-- 1 file changed, 29 insertions(+), 2 deletions(-) diff --git a/.github/workflows/eslint.yml b/.github/workflows/eslint.yml index 784d3e380..3b8411f74 100644 --- a/.github/workflows/eslint.yml +++ b/.github/workflows/eslint.yml @@ -7,15 +7,42 @@ on: branches: [main, master] jobs: + changes: + name: Check Changes + runs-on: ubuntu-latest + steps: + - name: Check Changes + uses: dorny/paths-filter@v2 + id: changes + with: + filters: | + eslint: + - '**.js,**.jsx,**.ts,**.tsx' + eslint: name: ESLint + needs: changes + if: needs.changes.outputs.eslint == 'true' runs-on: ubuntu-latest steps: - name: Checkout Code uses: actions/checkout@v3 - - name: Install modules - run: npm ci + - name: Cache Node Modules + uses: actions/cache@v3 + id: node_modules_cache_id + with: + path: "**/node_modules" + key: ${{ runner.os }}-eslint + + - name: Install Node Mudules + if: steps.node_modules_cache_id.outputs.cache-hit != 'true' + run: npm install \ + @typescript-eslint/eslint-plugin \ + @typescript-eslint/parser eslint \ + eslint-config-prettier \ + eslint-plugin-react + shell: bash - name: Run ESLint run: npx eslint . --ext .js,.jsx,.ts,.tsx From 7be1e6fff3dad15716e3f3cb32b67e74c840d9f4 Mon Sep 17 00:00:00 2001 From: chvmvd Date: Sat, 10 Dec 2022 23:19:13 +0900 Subject: [PATCH 15/20] Fix error in GitHub Actions --- .github/actions/build/action.yml | 1 + .pre-commit-config.yaml | 1 + 2 files changed, 2 insertions(+) diff --git a/.github/actions/build/action.yml b/.github/actions/build/action.yml index f197de250..d6a776490 100644 --- a/.github/actions/build/action.yml +++ b/.github/actions/build/action.yml @@ -1,3 +1,4 @@ +--- runs: using: "Composite" steps: diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 50066fef2..d7f0e90a0 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,3 +1,4 @@ +--- # See https://pre-commit.com for more information # See https://pre-commit.com/hooks.html for more hooks exclude: my-website/ From 5a3f249804de88035b0974113e9e9a5c79d67b08 Mon Sep 17 00:00:00 2001 From: chvmvd Date: Sat, 10 Dec 2022 23:22:06 +0900 Subject: [PATCH 16/20] Update black GitHub Actions --- .github/workflows/black.yml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/.github/workflows/black.yml b/.github/workflows/black.yml index 0d3cc12a0..7fcb86b31 100644 --- a/.github/workflows/black.yml +++ b/.github/workflows/black.yml @@ -7,8 +7,22 @@ on: branches: [main, master] jobs: + changes: + name: Check Changes + runs-on: ubuntu-latest + steps: + - name: Check Changes + uses: dorny/paths-filter@v2 + id: changes + with: + filters: | + black: + - '**.py,**.ipynb' + black: name: Black + needs: changes + if: needs.changes.outputs.eslint == 'true' runs-on: ubuntu-latest steps: - name: Checkout Code From b5a8960268e840c44aac7ab3acfc77a5b1ac8396 Mon Sep 17 00:00:00 2001 From: chvmvd Date: Sat, 10 Dec 2022 23:29:41 +0900 Subject: [PATCH 17/20] Fix error in GitHub Actions --- .github/workflows/black.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/black.yml b/.github/workflows/black.yml index 7fcb86b31..cec36d043 100644 --- a/.github/workflows/black.yml +++ b/.github/workflows/black.yml @@ -22,7 +22,7 @@ jobs: black: name: Black needs: changes - if: needs.changes.outputs.eslint == 'true' + if: needs.changes.outputs.black == 'true' runs-on: ubuntu-latest steps: - name: Checkout Code From 6b9a11b94f8c51a4471c32fc16ba2c18a0b1eb98 Mon Sep 17 00:00:00 2001 From: chvmvd Date: Sat, 10 Dec 2022 23:56:00 +0900 Subject: [PATCH 18/20] Remove MD013 --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index d7f0e90a0..31864a093 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -36,7 +36,7 @@ repos: rev: v0.12.0 hooks: - id: markdownlint - args: [-r, ~MD033] + args: [-r, "~MD033, ~MD013"] - repo: https://github.com/nbQA-dev/nbQA rev: 1.5.3 hooks: From a811af171208b94db44be291452d05bd7bff7083 Mon Sep 17 00:00:00 2001 From: chvmvd Date: Sun, 11 Dec 2022 00:04:06 +0900 Subject: [PATCH 19/20] Add Badge to README.md --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 6107c35e0..de3a2dea8 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,5 @@ +[![Build and Deploy](https://github.com/sikepuri-algorithm/sikepuri-algorithm.github.io/actions/workflows/deploy.yml/badge.svg)](https://github.com/sikepuri-algorithm/sikepuri-algorithm.github.io/actions/workflows/deploy.yml) [![Super Linter](https://github.com/sikepuri-algorithm/sikepuri-algorithm.github.io/actions/workflows/super_linter.yml/badge.svg)](https://github.com/sikepuri-algorithm/sikepuri-algorithm.github.io/actions/workflows/super_linter.yml) [![Black](https://github.com/sikepuri-algorithm/sikepuri-algorithm.github.io/actions/workflows/black.yml/badge.svg)](https://github.com/sikepuri-algorithm/sikepuri-algorithm.github.io/actions/workflows/black.yml) [![Prettier](https://github.com/sikepuri-algorithm/sikepuri-algorithm.github.io/actions/workflows/prettier.yml/badge.svg)](https://github.com/sikepuri-algorithm/sikepuri-algorithm.github.io/actions/workflows/prettier.yml) [![ESLint](https://github.com/sikepuri-algorithm/sikepuri-algorithm.github.io/actions/workflows/eslint.yml/badge.svg)](https://github.com/sikepuri-algorithm/sikepuri-algorithm.github.io/actions/workflows/eslint.yml) +
logo
From 60816351a7f9d8a782cd5cf15441f53a6f1a17c3 Mon Sep 17 00:00:00 2001 From: chvmvd Date: Sun, 11 Dec 2022 00:49:13 +0900 Subject: [PATCH 20/20] Update Prettier GitHub Actions --- .github/workflows/prettier.yml | 23 +++++++++++++++++++---- 1 file changed, 19 insertions(+), 4 deletions(-) diff --git a/.github/workflows/prettier.yml b/.github/workflows/prettier.yml index 4673cddb6..8540d657e 100644 --- a/.github/workflows/prettier.yml +++ b/.github/workflows/prettier.yml @@ -3,8 +3,8 @@ name: Prettier on: push: - # pull_request: - # branches: [master, main] + pull_request: + branches: [master, main] jobs: prettier: @@ -16,7 +16,22 @@ jobs: with: ref: ${{ github.head_ref }} + - name: Cache Node Modules + uses: actions/cache@v3 + id: node_modules_cache_id + with: + path: "**/node_modules" + key: ${{ runner.os }}-${{ hashFiles('**/package-lock.json') }} + + - name: Install Node Mudules + if: steps.node_modules_cache_id.outputs.cache-hit != 'true' + run: npm ci + shell: bash + - name: Run Prettier - uses: creyD/prettier_action@v4.2 + run: npx prettier --write . + + - name: Commit + uses: stefanzweifel/git-auto-commit-action@v4 with: - prettier_options: --write . + commit_message: Formatted!