Skip to content

Commit ee81354

Browse files
committed
feat: remove no more used /docs
1 parent c2ed437 commit ee81354

37 files changed

+6
-6904
lines changed

.github/workflows/build.yml

Lines changed: 1 addition & 99 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ on:
1010
options:
1111
- client
1212
- server
13-
- docs
1413
push:
1514
branches:
1615
- main
@@ -166,101 +165,4 @@ jobs:
166165
body: 'Server Build and Deploy triggered and completed. Job is ${{ job.status }}.'
167166
url: '${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}'
168167
icon: 'https://i.ibb.co/7d8rL1c3/Git-Hub-Mark-ea2971cee799.jpg'
169-
if: always() # Run this step regardless of the outcome of previous steps
170-
171-
build-and-deploy-docs:
172-
name: Build and Deploy /docs
173-
if: >
174-
(github.event_name == 'workflow_dispatch' && github.event.inputs.target == 'docs') ||
175-
(github.event_name == 'push' && contains(github.event.head_commit.message, 'chore(build/docs): trigger build action'))
176-
runs-on: ubuntu-latest
177-
178-
steps:
179-
- name: Checkout code
180-
uses: actions/checkout@v4
181-
182-
- uses: tsickert/discord-webhook@v7.0.0
183-
with:
184-
webhook-url: ${{ secrets.BUILD_WEBHOOK_URL }}
185-
embed-title: 'Deployment Notification'
186-
embed-description: 'Deployment triggered. Proceeding with build and restart.'
187-
embed-footer-text: 'docs.discord.place'
188-
embed-color: 14194756
189-
if: always()
190-
191-
- name: Set up SSH
192-
run: |
193-
mkdir -p ~/.ssh
194-
echo "${{ secrets.SSH_PRIVATE_KEY }}" > ~/.ssh/id_rsa
195-
chmod 600 ~/.ssh/id_rsa
196-
if: always()
197-
198-
- name: Deploy to Server
199-
env:
200-
SSH_PORT: ${{ secrets.SSH_PORT }}
201-
SSH_USER: ${{ secrets.SSH_USER }}
202-
SSH_HOST: ${{ secrets.SSH_HOST }}
203-
run: |
204-
ssh -T -o StrictHostKeyChecking=accept-new -p "$SSH_PORT" "$SSH_USER@$SSH_HOST" << 'EOF' > /dev/null 2>&1
205-
set -e
206-
207-
LOG_FILE="/tmp/discord-place-docs-deploy-$(date +%Y%m%d_%H%M%S).log"
208-
exec > >(tee -a "$LOG_FILE") 2>&1
209-
210-
echo "=== discord.place Docs Deployment Started at $(date) ==="
211-
echo "Log file: $LOG_FILE"
212-
213-
echo "Updating source code..."
214-
cd discord.place/docs
215-
git pull origin main
216-
217-
echo "Setting up Node environment..."
218-
export NVM_DIR="$HOME/.nvm"
219-
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"
220-
nvm use $(nvm current)
221-
222-
TEMP_DIR="/tmp/discord-place-docs-build-$(date +%s)"
223-
echo "Creating temporary build directory: $TEMP_DIR"
224-
mkdir -p "$TEMP_DIR"
225-
226-
echo "Copying docs files to temporary directory..."
227-
rsync -av --exclude='.git' --exclude='node_modules' . "$TEMP_DIR/"
228-
229-
echo "Installing dependencies in temporary directory..."
230-
cd "$TEMP_DIR"
231-
pnpm install --frozen-lockfile
232-
233-
echo "Building docs in temporary directory..."
234-
pnpm build
235-
236-
echo "Stopping docs application..."
237-
pm2 stop docs.discord.place
238-
239-
echo "Replacing build folder in production directory..."
240-
cd /root/discord.place/docs
241-
rm -rf .next # or the equivalent build folder if different
242-
mv "$TEMP_DIR/.next" ./
243-
244-
echo "Updating production dependencies..."
245-
pnpm install --frozen-lockfile
246-
247-
echo "Starting docs application..."
248-
pm2 restart docs.discord.place
249-
250-
echo "Cleaning up temporary directory..."
251-
rm -rf "$TEMP_DIR"
252-
253-
echo "=== discord.place Docs Deployment Completed Successfully at $(date) ==="
254-
echo "Log file saved to: $LOG_FILE"
255-
EOF
256-
if: always()
257-
258-
- uses: chimpdev/bark-github-action@v1.0.1
259-
with:
260-
device_key: ${{ secrets.BARK_KEY }}
261-
server_url: ${{ secrets.BARK_SERVER_URL }}
262-
title: '${{ github.repository }}'
263-
body: 'Docs Build and Deploy triggered and completed. Job is ${{ job.status }}.'
264-
url: '${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}'
265-
icon: 'https://i.ibb.co/7d8rL1c3/Git-Hub-Mark-ea2971cee799.jpg'
266-
if: always()
168+
if: always() # Run this step regardless of the outcome of previous steps

.github/workflows/eslint-docs.yml

Lines changed: 0 additions & 36 deletions
This file was deleted.

.github/workflows/release-please.yml

Lines changed: 1 addition & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,6 @@ jobs:
1919
server--release_created: ${{ steps.release.outputs.server--release_created}}
2020
client--tag_name: ${{ steps.release.outputs.client--tag_name}}
2121
client--release_created: ${{ steps.release.outputs.client--release_created}}
22-
docs--tag_name: ${{ steps.release.outputs.docs--tag_name}}
23-
docs--release_created: ${{ steps.release.outputs.docs--release_created}}
2422
steps:
2523
- uses: googleapis/release-please-action@v4
2624
id: release
@@ -71,26 +69,4 @@ jobs:
7169
- name: Upload Release Artifact
7270
env:
7371
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
74-
run: gh release upload ${{ needs.release-please.outputs.client--tag_name }} client.zip
75-
76-
release-docs:
77-
if: ${{needs.release-please.outputs.docs--release_created}}
78-
runs-on: ubuntu-latest
79-
needs: release-please
80-
steps:
81-
- uses: actions/checkout@v4
82-
- name: Setup pnpm
83-
uses: pnpm/action-setup@v4
84-
with:
85-
version: 9
86-
- uses: ./.github/actions/setup-node-env
87-
with:
88-
node-version: 18
89-
cache-path: docs/node_modules
90-
cache-key: "${{hashFiles('docs/pnpm-lock.yaml')}}"
91-
project: docs
92-
- run: zip -r docs.zip docs -x "**/node_modules/*"
93-
- name: Upload Release Artifact
94-
env:
95-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
96-
run: gh release upload ${{ needs.release-please.outputs.docs--tag_name }} docs.zip
72+
run: gh release upload ${{ needs.release-please.outputs.client--tag_name }} client.zip

.release-please-manifest.json

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
{
2-
"server": "1.18.0",
3-
"client": "1.22.0",
4-
"docs": "1.4.0"
2+
"server": "1.17.0",
3+
"client": "1.22.0"
54
}

.vscode/settings.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
2-
"eslint.workingDirectories": [ "./client", "./server", "./docs" ]
2+
"eslint.workingDirectories": [ "./client", "./server" ]
33
}

README.md

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ discord.place is your comprehensive hub for everything related to Discord. Wheth
66

77
From finding perfect emojis for your Discord servers to discovering the latest bots and servers, discord.place caters to all your Discord needs. Enjoy easy navigation and up-to-date content designed to help you make the most out of your Discord interactions.
88

9-
This repository contains the client, server and docs (no more used) files for the discord.place website.
9+
This repository contains the client and server files for the discord.place website.
1010

1111
---
1212

@@ -65,16 +65,7 @@ cd client
6565
npm run dev
6666
```
6767

68-
8. Start the docs (optional, no more used):
69-
70-
```bash
71-
cd docs
72-
73-
npm run dev
74-
```
75-
7668
8. Open your browser and navigate to `http://localhost:3000` to view the website locally.
77-
9. Open your browser and navigate to `http://localhost:3003` to view the documentation locally. (optional, no more used)
7869

7970
---
8071

docs/.eslintrc.js

Lines changed: 0 additions & 156 deletions
This file was deleted.

0 commit comments

Comments
 (0)