From 2d6a7ad98677cc609e7cbe17ca3ff0c065ccfa81 Mon Sep 17 00:00:00 2001 From: jowi Date: Sun, 6 Oct 2024 10:28:22 -0400 Subject: [PATCH] chore(repo): initialize repository --- .github/workflows/BUILD.yml | 43 +++++++++++++++++++++++++++++++++++++ .gitignore | 2 ++ Dockerfile | 11 ++++++++++ LICENCE.md | 21 ++++++++++++++++++ README.md | 1 + TODO.md | 7 ++++++ bin/dirclean.sh | 3 +++ 7 files changed, 88 insertions(+) create mode 100644 .github/workflows/BUILD.yml create mode 100644 .gitignore create mode 100644 Dockerfile create mode 100644 LICENCE.md create mode 100644 README.md create mode 100644 TODO.md create mode 100644 bin/dirclean.sh diff --git a/.github/workflows/BUILD.yml b/.github/workflows/BUILD.yml new file mode 100644 index 0000000..52ed21c --- /dev/null +++ b/.github/workflows/BUILD.yml @@ -0,0 +1,43 @@ +name: Build + +on: + push: + branches: 'main' + +jobs: + # lint: + # name: Lint project 🧹 + # runs-on: ubuntu-latest + + # steps: + # - + # name: Checkout repository + # uses: actions/checkout@v4 + # - + # name: Set up ShellCheck + # run: sudo apt-get install -y spellcheck + # - + # name: Run spellcheck + # run: spellcheck **/*.sh + + + build: + name: Create Docker image 📷 + runs-on: ubuntu-latest + # needs: [lint] + steps: + - + name: Login to Docker Hub + uses: docker/login-action@v3 + with: + username: ${{ vars.DOCKERHUB_USERNAME }} + password: ${{ secrets.DOCKERHUB_TOKEN }} + - + name: Set up Docker Buildx + uses: docker/setup-buildx-action@v3 + - + name: Build and Push + uses: docker/build-push-action@v6 + with: + push: true + tags: ${{ vars.DOCKERHUB_USERNAME }}/dirclean:latest diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..a20c503 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +logs/ +tmp/ diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..58a4d5f --- /dev/null +++ b/Dockerfile @@ -0,0 +1,11 @@ +FROM ubuntu:latest + +RUN apt-get update && apt-get install -y \ + shellcheck \ + && rm -rf /var/lib/apt/lists/* + +WORKDIR /app + +COPY . . + +CMD ["shellcheck", "**/*.sh"] \ No newline at end of file diff --git a/LICENCE.md b/LICENCE.md new file mode 100644 index 0000000..2eda3f1 --- /dev/null +++ b/LICENCE.md @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2024 Jowi + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..1bc11e6 --- /dev/null +++ b/README.md @@ -0,0 +1 @@ +Script for categorizing directories & files based on file types. \ No newline at end of file diff --git a/TODO.md b/TODO.md new file mode 100644 index 0000000..9798f3e --- /dev/null +++ b/TODO.md @@ -0,0 +1,7 @@ +[ ] Create main entry point, test it out +[ ] Attempt using with CLI +[ ] Make CLI help command +[ ] Add configs +[ ] Add linter +[ ] Initialize README +[ ] Set up Semantic-release \ No newline at end of file diff --git a/bin/dirclean.sh b/bin/dirclean.sh new file mode 100644 index 0000000..aeea7c7 --- /dev/null +++ b/bin/dirclean.sh @@ -0,0 +1,3 @@ +#!/bin/bash + +echo "I love clean repositories!"