diff --git a/.github/workflows/PRD_build.yml b/.github/workflows/PRD_build.yml new file mode 100644 index 0000000..939d6ee --- /dev/null +++ b/.github/workflows/PRD_build.yml @@ -0,0 +1,21 @@ +--- +name: PRD Push + +on: + workflow_dispatch: + +jobs: + Deployment_PRD: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Upload to PRD + uses: SamKirkland/FTP-Deploy-Action@v4.3.5 + with: + server: ${{ secrets.FTP_SRV }} + username: ${{ secrets.FTP_USERNAME }} + password: ${{ secrets.FTP_PASSWORD }} + server-dir: ${{ secrets.FTP_PRD_DIR }}/ + local-dir: www/ diff --git a/.github/workflows/lints.yml b/.github/workflows/lints.yml deleted file mode 100644 index 3481d68..0000000 --- a/.github/workflows/lints.yml +++ /dev/null @@ -1,20 +0,0 @@ ---- -name: HTML Lints - -on: - push: - branches: - - '**' - -jobs: - HTML_Lint: - runs-on: ubuntu-latest - container: - image: ghcr.io/cradle8810/htmllint:latest - steps: - - - name: Checkout - uses: actions/checkout@v3 - - - name: Execute HTMLlint - run: htmllint diff --git a/.github/workflows/sitemap.yml b/.github/workflows/sitemap.yml deleted file mode 100644 index 3f8dcb8..0000000 --- a/.github/workflows/sitemap.yml +++ /dev/null @@ -1,30 +0,0 @@ ---- -name: Make sitemap.txt - -on: - push: - branches: - - 'master' - -jobs: - Sitemap_txt: - runs-on: ubuntu-latest - steps: - - name: Checkout - uses: actions/checkout@v4 - - - name: find html files and output as sitemap.txt - run: | - find . -type f -name "*.html" | \ - sed 's#\.\/#http:\/\/hayaworld\.net/#g' | \ - sed 's#\/www##g' \ - > www/sitemap.txt - - - name: View sitemap.txt - run: cat "www/sitemap.txt" - - - name: Upload sitemap.txt as artifacts - uses: actions/upload-artifact@v4 - with: - name: sitemap.txt - path: www/sitemap.txt diff --git a/.github/workflows/workflows.yml b/.github/workflows/workflows.yml new file mode 100644 index 0000000..61acda9 --- /dev/null +++ b/.github/workflows/workflows.yml @@ -0,0 +1,61 @@ +--- +name: Lints and STG upload + +on: + push: + branches: + - '**' + +jobs: + HTML_Lint: + runs-on: ubuntu-latest + container: + image: ghcr.io/cradle8810/htmllint:latest + steps: + + - name: Checkout + uses: actions/checkout@v3 + + - name: Execute HTMLlint + run: htmllint + + Sitemap_txt: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: find html files and output as sitemap.txt + run: | + find . -type f -name "*.html" | \ + sed 's#\.\/#http:\/\/hayaworld\.net/#g' | \ + sed 's#\/www##g' \ + > www/sitemap.txt + + - name: View sitemap.txt + run: cat "www/sitemap.txt" + + - name: Upload sitemap.txt as artifacts + uses: actions/upload-artifact@v4 + with: + name: sitemap.txt + path: www/sitemap.txt + + Deployment_STG: + needs: + - HTML_Lint + - Sitemap_txt + + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Upload to STG + uses: SamKirkland/FTP-Deploy-Action@v4.3.5 + with: + server: ${{ secrets.FTP_SRV }} + username: ${{ secrets.FTP_USERNAME }} + password: ${{ secrets.FTP_PASSWORD }} + server-dir: ${{ secrets.FTP_STG_DIR }}/ + local-dir: www/