17 Commits

Author SHA1 Message Date
minori ea0f21e657 deps: update discord.js to 14.25.1
Node.js CI / CI (pull_request) Successful in 26s
Security Scan and Upload / Security & DefectDojo Upload (pull_request) Successful in 1m26s
2026-02-04 08:22:08 -08:00
hikari 2a8f9bd7ae docs: update feedback section to use support forum
Node.js CI / CI (push) Successful in 19s
Security Scan and Upload / Security & DefectDojo Upload (push) Successful in 1m33s
2026-01-26 12:37:05 -08:00
naomi f11b8273c2 feat: automated upload of .gitea/workflows/ci.yml
Node.js CI / CI (push) Successful in 22s
Security Scan and Upload / Security & DefectDojo Upload (push) Successful in 58s
2025-12-22 19:42:19 +01:00
naomi 9c0d38f61a feat: automated upload of .gitea/workflows/ci.yml
Node.js CI / CI (push) Has been cancelled
Security Scan and Upload / Security & DefectDojo Upload (push) Has been cancelled
2025-12-22 19:35:47 +01:00
naomi 7ebb556d1b feat: automated upload of .gitea/workflows/ci.yml
Node.js CI / Lint and Test (push) Has been cancelled
Security Scan and Upload / Security & DefectDojo Upload (push) Has been cancelled
2025-12-22 19:25:36 +01:00
naomi bfe7f682c0 feat: automated upload of .npmrc
Node.js CI / Lint and Test (push) Has been cancelled
Security Scan and Upload / Security & DefectDojo Upload (push) Has been cancelled
2025-12-22 19:16:26 +01:00
naomi 24e3793eec feat: automated upload of .gitea/workflows/security.yml
Node.js CI / Lint and Test (push) Successful in 22s
Security Scan and Upload / Security & DefectDojo Upload (push) Successful in 1m1s
2025-12-18 03:08:18 +01:00
naomi 61ecc80e9a feat: automated upload of .gitea/workflows/security.yml
Node.js CI / Lint and Test (push) Successful in 22s
Security Scan and Upload / Security & DefectDojo Upload (push) Successful in 1m0s
2025-12-17 23:26:18 +01:00
naomi 2c46672a81 feat: automated upload of .gitea/workflows/security.yml
Node.js CI / Lint and Test (push) Successful in 20s
Security Scan / Security Audit (push) Failing after 6m54s
2025-12-12 03:38:03 +01:00
naomi 0387262581 feat: automated delete of .gitea/workflows/sonar.yml
Node.js CI / Lint and Test (push) Successful in 18s
Security Scan / Trivy Security Scan (push) Failing after 4m48s
2025-12-12 00:15:15 +01:00
naomi efa6028b4c feat: automated upload of .gitea/workflows/security.yml
Node.js CI / Lint and Test (push) Successful in 19s
Security Scan / Trivy Security Scan (push) Failing after 4m48s
Code Analysis / SonarQube (push) Failing after 4m47s
2025-12-11 20:12:08 +01:00
naomi d56d5dcbfc chore: cyc cohort is over
Code Analysis / SonarQube (push) Failing after 18s
Node.js CI / Lint and Test (push) Successful in 38s
2025-08-14 09:55:50 -07:00
naomi efaf3dce16 feat: add mentorship channel
Code Analysis / SonarQube (push) Failing after 17s
Node.js CI / Lint and Test (push) Successful in 38s
2025-07-31 17:05:29 -07:00
naomi 0441f1c68a chore: remove freecodecamp channels
Code Analysis / SonarQube (push) Failing after 22s
Node.js CI / Lint and Test (push) Successful in 45s
2025-07-29 10:02:53 -07:00
naomi fa1d627178 feat: add support for dsd cohort channels
Code Analysis / SonarQube (push) Failing after 17s
Node.js CI / Lint and Test (push) Successful in 36s
2025-07-14 17:44:55 -07:00
naomi c0b21ce82f feat: confirm participation
Code Analysis / SonarQube (push) Failing after 14s
Node.js CI / Lint and Test (push) Successful in 34s
2025-07-02 14:48:50 -07:00
naomi 8121f3bb6d feat: only assign participation in Maribelle's threads
Code Analysis / SonarQube (push) Failing after 16s
Node.js CI / Lint and Test (push) Successful in 35s
2025-07-02 14:29:18 -07:00
10 changed files with 295 additions and 183 deletions
+13 -4
View File
@@ -8,23 +8,32 @@ on:
- main - main
jobs: jobs:
lint: ci:
name: Lint and Test name: CI
runs-on: ubuntu-latest
steps: steps:
- name: Checkout Source Files - name: Checkout Source Files
uses: actions/checkout@v4 uses: actions/checkout@v4
- name: Use Node.js v22 - name: Use Node.js v24
uses: actions/setup-node@v4 uses: actions/setup-node@v4
with: with:
node-version: 22 node-version: 24
- name: Setup pnpm - name: Setup pnpm
uses: pnpm/action-setup@v2 uses: pnpm/action-setup@v2
with: with:
version: 10 version: 10
- name: Ensure Dependencies are Pinned
uses: naomi-lgbt/dependency-pin-check@main
with:
language: javascript
dev-dependencies: true
peer-dependencies: true
optional-dependencies: true
- name: Install Dependencies - name: Install Dependencies
run: pnpm install run: pnpm install
+177
View File
@@ -0,0 +1,177 @@
name: Security Scan and Upload
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
schedule:
- cron: '0 0 * * 1'
workflow_dispatch:
jobs:
security-audit:
name: Security & DefectDojo Upload
runs-on: ubuntu-latest
continue-on-error: true
steps:
- name: Checkout code
uses: actions/checkout@v4
# --- AUTO-SETUP PROJECT ---
- name: Ensure DefectDojo Product Exists
env:
DD_URL: ${{ secrets.DD_URL }}
DD_TOKEN: ${{ secrets.DD_TOKEN }}
PRODUCT_NAME: ${{ github.repository }}
PRODUCT_TYPE_ID: 1
run: |
sudo apt-get install jq -y > /dev/null
echo "Checking connection to $DD_URL..."
# Check if product exists - capture HTTP code to debug connection issues
RESPONSE=$(curl --write-out "%{http_code}" --silent --output /tmp/response.json \
-H "Authorization: Token $DD_TOKEN" \
"$DD_URL/api/v2/products/?name=$PRODUCT_NAME")
# If response is not 200, print error
if [ "$RESPONSE" != "200" ]; then
echo "::error::Failed to query DefectDojo. HTTP Code: $RESPONSE"
cat /tmp/response.json
exit 1
fi
COUNT=$(cat /tmp/response.json | jq -r '.count')
if [ "$COUNT" = "0" ]; then
echo "Creating product '$PRODUCT_NAME'..."
curl -s -X POST "$DD_URL/api/v2/products/" \
-H "Authorization: Token $DD_TOKEN" \
-H "Content-Type: application/json" \
-d '{ "name": "'"$PRODUCT_NAME"'", "description": "Auto-created by Gitea Actions", "prod_type": '$PRODUCT_TYPE_ID' }'
else
echo "Product '$PRODUCT_NAME' already exists."
fi
# --- 1. TRIVY (Dependencies & Misconfig) ---
- name: Install Trivy
run: |
sudo apt-get install wget apt-transport-https gnupg lsb-release -y
wget -qO - https://aquasecurity.github.io/trivy-repo/deb/public.key | sudo apt-key add -
echo "deb https://aquasecurity.github.io/trivy-repo/deb $(lsb_release -sc) main" | sudo tee -a /etc/apt/sources.list.d/trivy.list
sudo apt-get update && sudo apt-get install trivy -y
- name: Run Trivy (FS Scan)
run: |
trivy fs . --scanners vuln,misconfig --format json --output trivy-results.json --exit-code 0
- name: Upload Trivy to DefectDojo
env:
DD_URL: ${{ secrets.DD_URL }}
DD_TOKEN: ${{ secrets.DD_TOKEN }}
run: |
echo "Uploading Trivy results..."
# Generate today's date in YYYY-MM-DD format
TODAY=$(date +%Y-%m-%d)
HTTP_CODE=$(curl --write-out "%{http_code}" --output response.txt --silent -X POST "$DD_URL/api/v2/import-scan/" \
-H "Authorization: Token $DD_TOKEN" \
-F "active=true" \
-F "verified=true" \
-F "scan_type=Trivy Scan" \
-F "engagement_name=CI/CD Pipeline" \
-F "product_name=${{ github.repository }}" \
-F "scan_date=$TODAY" \
-F "auto_create_context=true" \
-F "file=@trivy-results.json")
if [[ "$HTTP_CODE" != "200" && "$HTTP_CODE" != "201" ]]; then
echo "::error::Upload Failed with HTTP $HTTP_CODE"
echo "--- SERVER RESPONSE ---"
cat response.txt
echo "-----------------------"
exit 1
else
echo "Upload Success!"
fi
# --- 2. GITLEAKS (Secrets) ---
- name: Install Gitleaks
run: |
wget -qO gitleaks.tar.gz https://github.com/gitleaks/gitleaks/releases/download/v8.18.0/gitleaks_8.18.0_linux_x64.tar.gz
tar -xzf gitleaks.tar.gz
sudo mv gitleaks /usr/local/bin/ && chmod +x /usr/local/bin/gitleaks
- name: Run Gitleaks
run: gitleaks detect --source . -v --report-path gitleaks-results.json --report-format json --no-git || true
- name: Upload Gitleaks to DefectDojo
env:
DD_URL: ${{ secrets.DD_URL }}
DD_TOKEN: ${{ secrets.DD_TOKEN }}
run: |
echo "Uploading Gitleaks results..."
TODAY=$(date +%Y-%m-%d)
HTTP_CODE=$(curl --write-out "%{http_code}" --output response.txt --silent -X POST "$DD_URL/api/v2/import-scan/" \
-H "Authorization: Token $DD_TOKEN" \
-F "active=true" \
-F "verified=true" \
-F "scan_type=Gitleaks Scan" \
-F "engagement_name=CI/CD Pipeline" \
-F "product_name=${{ github.repository }}" \
-F "scan_date=$TODAY" \
-F "auto_create_context=true" \
-F "file=@gitleaks-results.json")
if [[ "$HTTP_CODE" != "200" && "$HTTP_CODE" != "201" ]]; then
echo "::error::Upload Failed with HTTP $HTTP_CODE"
echo "--- SERVER RESPONSE ---"
cat response.txt
echo "-----------------------"
exit 1
else
echo "Upload Success!"
fi
# --- 3. SEMGREP (SAST) ---
- name: Install Semgrep (via pipx)
run: |
sudo apt-get install pipx -y
pipx install semgrep
# Add pipx binary path to GITHUB_PATH so next steps can see 'semgrep'
echo "$HOME/.local/bin" >> $GITHUB_PATH
- name: Run Semgrep
run: semgrep scan --config=p/security-audit --config=p/owasp-top-ten --json --output semgrep-results.json . || true
- name: Upload Semgrep to DefectDojo
env:
DD_URL: ${{ secrets.DD_URL }}
DD_TOKEN: ${{ secrets.DD_TOKEN }}
run: |
echo "Uploading Semgrep results..."
TODAY=$(date +%Y-%m-%d)
HTTP_CODE=$(curl --write-out "%{http_code}" --output response.txt --silent -X POST "$DD_URL/api/v2/import-scan/" \
-H "Authorization: Token $DD_TOKEN" \
-F "active=true" \
-F "verified=true" \
-F "scan_type=Semgrep JSON Report" \
-F "engagement_name=CI/CD Pipeline" \
-F "product_name=${{ github.repository }}" \
-F "scan_date=$TODAY" \
-F "auto_create_context=true" \
-F "file=@semgrep-results.json")
if [[ "$HTTP_CODE" != "200" && "$HTTP_CODE" != "201" ]]; then
echo "::error::Upload Failed with HTTP $HTTP_CODE"
echo "--- SERVER RESPONSE ---"
cat response.txt
echo "-----------------------"
exit 1
else
echo "Upload Success!"
fi
-34
View File
@@ -1,34 +0,0 @@
name: Code Analysis
on:
push:
branches:
- main
jobs:
sonar:
name: SonarQube
steps:
- name: Checkout Source Files
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: SonarCube Scan
uses: SonarSource/sonarqube-scan-action@v4
timeout-minutes: 10
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
SONAR_HOST_URL: "https://quality.nhcarrigan.com"
with:
args: >
-Dsonar.sources=.
-Dsonar.projectKey=standup-bot
- name: SonarQube Quality Gate check
uses: sonarsource/sonarqube-quality-gate-action@v1
with:
pollingTimeoutSec: 600
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
SONAR_HOST_URL: "https://quality.nhcarrigan.com"
+25
View File
@@ -0,0 +1,25 @@
# Package Manager Configuration
# Force pnpm usage - breaks npm/yarn intentionally
node-linker=pnpm
# Security: Disable all lifecycle scripts
ignore-scripts=true
enable-pre-post-scripts=false
# Security: Require packages to be 10+ days old before installation
minimum-release-age=14400
# Security: Verify package integrity hashes
verify-store-integrity=true
# Security: Enforce strict trust policies
trust-policy=strict
# Security: Strict peer dependency resolution
strict-peer-dependencies=true
# Performance: Use symlinks for node_modules
symlink=true
# Lockfile: Ensure lockfile is not modified during install
frozen-lockfile=false
+1 -1
View File
@@ -18,7 +18,7 @@ This page is currently deployed. [View the live website.]
## Feedback and Bugs ## Feedback and Bugs
If you have feedback or a bug report, please feel free to open a GitHub issue! If you have feedback or a bug report, please [log a ticket on our forum](https://support.nhcarrigan.com).
## Contributing ## Contributing
+1 -1
View File
@@ -25,7 +25,7 @@
}, },
"dependencies": { "dependencies": {
"@nhcarrigan/logger": "1.0.0", "@nhcarrigan/logger": "1.0.0",
"discord.js": "14.21.0", "discord.js": "14.25.1",
"node-schedule": "2.1.1" "node-schedule": "2.1.1"
} }
} }
+46 -34
View File
@@ -12,8 +12,8 @@ importers:
specifier: 1.0.0 specifier: 1.0.0
version: 1.0.0 version: 1.0.0
discord.js: discord.js:
specifier: 14.21.0 specifier: 14.25.1
version: 14.21.0 version: 14.25.1
node-schedule: node-schedule:
specifier: 2.1.1 specifier: 2.1.1
version: 2.1.1 version: 2.1.1
@@ -112,8 +112,8 @@ packages:
resolution: {integrity: sha512-Y3IR1cRnOxOCDvMmNiym7XpXQ93iGDDPHx+Zj+NM+rg0fBaShfQLkg+hKPaZCEvg5N/LeCo4+Rj/i3FuJsIQaw==} resolution: {integrity: sha512-Y3IR1cRnOxOCDvMmNiym7XpXQ93iGDDPHx+Zj+NM+rg0fBaShfQLkg+hKPaZCEvg5N/LeCo4+Rj/i3FuJsIQaw==}
engines: {node: '>=6.9.0'} engines: {node: '>=6.9.0'}
'@discordjs/builders@1.11.2': '@discordjs/builders@1.13.1':
resolution: {integrity: sha512-F1WTABdd8/R9D1icJzajC4IuLyyS8f3rTOz66JsSI3pKvpCAtsMBweu8cyNYsIyvcrKAVn9EPK+Psoymq+XC0A==} resolution: {integrity: sha512-cOU0UDHc3lp/5nKByDxkmRiNZBpdp0kx55aarbiAfakfKJHlxv/yFW1zmIqCAmwH5CRlrH9iMFKJMpvW4DPB+w==}
engines: {node: '>=16.11.0'} engines: {node: '>=16.11.0'}
'@discordjs/collection@1.5.3': '@discordjs/collection@1.5.3':
@@ -124,16 +124,16 @@ packages:
resolution: {integrity: sha512-LiSusze9Tc7qF03sLCujF5iZp7K+vRNEDBZ86FT9aQAv3vxMLihUvKvpsCWiQ2DJq1tVckopKm1rxomgNUc9hg==} resolution: {integrity: sha512-LiSusze9Tc7qF03sLCujF5iZp7K+vRNEDBZ86FT9aQAv3vxMLihUvKvpsCWiQ2DJq1tVckopKm1rxomgNUc9hg==}
engines: {node: '>=18'} engines: {node: '>=18'}
'@discordjs/formatters@0.6.1': '@discordjs/formatters@0.6.2':
resolution: {integrity: sha512-5cnX+tASiPCqCWtFcFslxBVUaCetB0thvM/JyavhbXInP1HJIEU+Qv/zMrnuwSsX3yWH2lVXNJZeDK3EiP4HHg==} resolution: {integrity: sha512-y4UPwWhH6vChKRkGdMB4odasUbHOUwy7KL+OVwF86PvT6QVOwElx+TiI1/6kcmcEe+g5YRXJFiXSXUdabqZOvQ==}
engines: {node: '>=16.11.0'} engines: {node: '>=16.11.0'}
'@discordjs/rest@2.5.1': '@discordjs/rest@2.6.0':
resolution: {integrity: sha512-Tg9840IneBcbrAjcGaQzHUJWFNq1MMWZjTdjJ0WS/89IffaNKc++iOvffucPxQTF/gviO9+9r8kEPea1X5J2Dw==} resolution: {integrity: sha512-RDYrhmpB7mTvmCKcpj+pc5k7POKszS4E2O9TYc+U+Y4iaCP+r910QdO43qmpOja8LRr1RJ0b3U+CqVsnPqzf4w==}
engines: {node: '>=18'} engines: {node: '>=18'}
'@discordjs/util@1.1.1': '@discordjs/util@1.2.0':
resolution: {integrity: sha512-eddz6UnOBEB1oITPinyrB2Pttej49M9FZQY8NxgEvc3tq6ZICZ19m70RsmzRdDHk80O9NoYN/25AqJl8vPVf/g==} resolution: {integrity: sha512-3LKP7F2+atl9vJFhaBjn4nOaSWahZ/yWjOvA4e5pnXkt2qyXRCHLxoBQy81GFtLGCq7K9lPm9R517M1U+/90Qg==}
engines: {node: '>=18'} engines: {node: '>=18'}
'@discordjs/ws@1.2.3': '@discordjs/ws@1.2.3':
@@ -478,51 +478,61 @@ packages:
resolution: {integrity: sha512-A4iphFGNkWRd+5m3VIGuqHnG3MVnqKe7Al57u9mwgbyZ2/xF9Jio72MaY7xxh+Y87VAHmGQr73qoKL9HPbXj1g==} resolution: {integrity: sha512-A4iphFGNkWRd+5m3VIGuqHnG3MVnqKe7Al57u9mwgbyZ2/xF9Jio72MaY7xxh+Y87VAHmGQr73qoKL9HPbXj1g==}
cpu: [arm] cpu: [arm]
os: [linux] os: [linux]
libc: [glibc]
'@rollup/rollup-linux-arm-musleabihf@4.34.8': '@rollup/rollup-linux-arm-musleabihf@4.34.8':
resolution: {integrity: sha512-S0lqKLfTm5u+QTxlFiAnb2J/2dgQqRy/XvziPtDd1rKZFXHTyYLoVL58M/XFwDI01AQCDIevGLbQrMAtdyanpA==} resolution: {integrity: sha512-S0lqKLfTm5u+QTxlFiAnb2J/2dgQqRy/XvziPtDd1rKZFXHTyYLoVL58M/XFwDI01AQCDIevGLbQrMAtdyanpA==}
cpu: [arm] cpu: [arm]
os: [linux] os: [linux]
libc: [musl]
'@rollup/rollup-linux-arm64-gnu@4.34.8': '@rollup/rollup-linux-arm64-gnu@4.34.8':
resolution: {integrity: sha512-jpz9YOuPiSkL4G4pqKrus0pn9aYwpImGkosRKwNi+sJSkz+WU3anZe6hi73StLOQdfXYXC7hUfsQlTnjMd3s1A==} resolution: {integrity: sha512-jpz9YOuPiSkL4G4pqKrus0pn9aYwpImGkosRKwNi+sJSkz+WU3anZe6hi73StLOQdfXYXC7hUfsQlTnjMd3s1A==}
cpu: [arm64] cpu: [arm64]
os: [linux] os: [linux]
libc: [glibc]
'@rollup/rollup-linux-arm64-musl@4.34.8': '@rollup/rollup-linux-arm64-musl@4.34.8':
resolution: {integrity: sha512-KdSfaROOUJXgTVxJNAZ3KwkRc5nggDk+06P6lgi1HLv1hskgvxHUKZ4xtwHkVYJ1Rep4GNo+uEfycCRRxht7+Q==} resolution: {integrity: sha512-KdSfaROOUJXgTVxJNAZ3KwkRc5nggDk+06P6lgi1HLv1hskgvxHUKZ4xtwHkVYJ1Rep4GNo+uEfycCRRxht7+Q==}
cpu: [arm64] cpu: [arm64]
os: [linux] os: [linux]
libc: [musl]
'@rollup/rollup-linux-loongarch64-gnu@4.34.8': '@rollup/rollup-linux-loongarch64-gnu@4.34.8':
resolution: {integrity: sha512-NyF4gcxwkMFRjgXBM6g2lkT58OWztZvw5KkV2K0qqSnUEqCVcqdh2jN4gQrTn/YUpAcNKyFHfoOZEer9nwo6uQ==} resolution: {integrity: sha512-NyF4gcxwkMFRjgXBM6g2lkT58OWztZvw5KkV2K0qqSnUEqCVcqdh2jN4gQrTn/YUpAcNKyFHfoOZEer9nwo6uQ==}
cpu: [loong64] cpu: [loong64]
os: [linux] os: [linux]
libc: [glibc]
'@rollup/rollup-linux-powerpc64le-gnu@4.34.8': '@rollup/rollup-linux-powerpc64le-gnu@4.34.8':
resolution: {integrity: sha512-LMJc999GkhGvktHU85zNTDImZVUCJ1z/MbAJTnviiWmmjyckP5aQsHtcujMjpNdMZPT2rQEDBlJfubhs3jsMfw==} resolution: {integrity: sha512-LMJc999GkhGvktHU85zNTDImZVUCJ1z/MbAJTnviiWmmjyckP5aQsHtcujMjpNdMZPT2rQEDBlJfubhs3jsMfw==}
cpu: [ppc64] cpu: [ppc64]
os: [linux] os: [linux]
libc: [glibc]
'@rollup/rollup-linux-riscv64-gnu@4.34.8': '@rollup/rollup-linux-riscv64-gnu@4.34.8':
resolution: {integrity: sha512-xAQCAHPj8nJq1PI3z8CIZzXuXCstquz7cIOL73HHdXiRcKk8Ywwqtx2wrIy23EcTn4aZ2fLJNBB8d0tQENPCmw==} resolution: {integrity: sha512-xAQCAHPj8nJq1PI3z8CIZzXuXCstquz7cIOL73HHdXiRcKk8Ywwqtx2wrIy23EcTn4aZ2fLJNBB8d0tQENPCmw==}
cpu: [riscv64] cpu: [riscv64]
os: [linux] os: [linux]
libc: [glibc]
'@rollup/rollup-linux-s390x-gnu@4.34.8': '@rollup/rollup-linux-s390x-gnu@4.34.8':
resolution: {integrity: sha512-DdePVk1NDEuc3fOe3dPPTb+rjMtuFw89gw6gVWxQFAuEqqSdDKnrwzZHrUYdac7A7dXl9Q2Vflxpme15gUWQFA==} resolution: {integrity: sha512-DdePVk1NDEuc3fOe3dPPTb+rjMtuFw89gw6gVWxQFAuEqqSdDKnrwzZHrUYdac7A7dXl9Q2Vflxpme15gUWQFA==}
cpu: [s390x] cpu: [s390x]
os: [linux] os: [linux]
libc: [glibc]
'@rollup/rollup-linux-x64-gnu@4.34.8': '@rollup/rollup-linux-x64-gnu@4.34.8':
resolution: {integrity: sha512-8y7ED8gjxITUltTUEJLQdgpbPh1sUQ0kMTmufRF/Ns5tI9TNMNlhWtmPKKHCU0SilX+3MJkZ0zERYYGIVBYHIA==} resolution: {integrity: sha512-8y7ED8gjxITUltTUEJLQdgpbPh1sUQ0kMTmufRF/Ns5tI9TNMNlhWtmPKKHCU0SilX+3MJkZ0zERYYGIVBYHIA==}
cpu: [x64] cpu: [x64]
os: [linux] os: [linux]
libc: [glibc]
'@rollup/rollup-linux-x64-musl@4.34.8': '@rollup/rollup-linux-x64-musl@4.34.8':
resolution: {integrity: sha512-SCXcP0ZpGFIe7Ge+McxY5zKxiEI5ra+GT3QRxL0pMMtxPfpyLAKleZODi1zdRHkz5/BhueUrYtYVgubqe9JBNQ==} resolution: {integrity: sha512-SCXcP0ZpGFIe7Ge+McxY5zKxiEI5ra+GT3QRxL0pMMtxPfpyLAKleZODi1zdRHkz5/BhueUrYtYVgubqe9JBNQ==}
cpu: [x64] cpu: [x64]
os: [linux] os: [linux]
libc: [musl]
'@rollup/rollup-win32-arm64-msvc@4.34.8': '@rollup/rollup-win32-arm64-msvc@4.34.8':
resolution: {integrity: sha512-YHYsgzZgFJzTRbth4h7Or0m5O74Yda+hLin0irAIobkLQFRQd1qWmnoVfwmKm9TXIZVAD0nZ+GEb2ICicLyCnQ==} resolution: {integrity: sha512-YHYsgzZgFJzTRbth4h7Or0m5O74Yda+hLin0irAIobkLQFRQd1qWmnoVfwmKm9TXIZVAD0nZ+GEb2ICicLyCnQ==}
@@ -981,11 +991,11 @@ packages:
resolution: {integrity: sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==} resolution: {integrity: sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==}
engines: {node: '>=8'} engines: {node: '>=8'}
discord-api-types@0.38.13: discord-api-types@0.38.37:
resolution: {integrity: sha512-FELWJRgLVQuR7Az8RhdEZE0k6QNjSW9PCUcU1iyP2Gke8HrJmnMceSS9pD93UM64s3tvZzJPajpPLjWZJylf4g==} resolution: {integrity: sha512-Cv47jzY1jkGkh5sv0bfHYqGgKOWO1peOrGMkDFM4UmaGMOTgOW8QSexhvixa9sVOiz8MnVOBryWYyw/CEVhj7w==}
discord.js@14.21.0: discord.js@14.25.1:
resolution: {integrity: sha512-U5w41cEmcnSfwKYlLv5RJjB8Joa+QJyRwIJz5i/eg+v2Qvv6EYpCRhN9I2Rlf0900LuqSDg8edakUATrDZQncQ==} resolution: {integrity: sha512-2l0gsPOLPs5t6GFZfQZKnL1OJNYFcuC/ETWsW4VtKVD/tg4ICa9x+jb9bkPffkMdRpRpuUaO/fKkHCBeiCKh8g==}
engines: {node: '>=18'} engines: {node: '>=18'}
doctrine@2.1.0: doctrine@2.1.0:
@@ -2407,12 +2417,12 @@ snapshots:
'@babel/helper-string-parser': 7.25.9 '@babel/helper-string-parser': 7.25.9
'@babel/helper-validator-identifier': 7.25.9 '@babel/helper-validator-identifier': 7.25.9
'@discordjs/builders@1.11.2': '@discordjs/builders@1.13.1':
dependencies: dependencies:
'@discordjs/formatters': 0.6.1 '@discordjs/formatters': 0.6.2
'@discordjs/util': 1.1.1 '@discordjs/util': 1.2.0
'@sapphire/shapeshift': 4.0.0 '@sapphire/shapeshift': 4.0.0
discord-api-types: 0.38.13 discord-api-types: 0.38.37
fast-deep-equal: 3.1.3 fast-deep-equal: 3.1.3
ts-mixer: 6.0.4 ts-mixer: 6.0.4
tslib: 2.8.1 tslib: 2.8.1
@@ -2421,33 +2431,35 @@ snapshots:
'@discordjs/collection@2.1.1': {} '@discordjs/collection@2.1.1': {}
'@discordjs/formatters@0.6.1': '@discordjs/formatters@0.6.2':
dependencies: dependencies:
discord-api-types: 0.38.13 discord-api-types: 0.38.37
'@discordjs/rest@2.5.1': '@discordjs/rest@2.6.0':
dependencies: dependencies:
'@discordjs/collection': 2.1.1 '@discordjs/collection': 2.1.1
'@discordjs/util': 1.1.1 '@discordjs/util': 1.2.0
'@sapphire/async-queue': 1.5.5 '@sapphire/async-queue': 1.5.5
'@sapphire/snowflake': 3.5.3 '@sapphire/snowflake': 3.5.3
'@vladfrangu/async_event_emitter': 2.4.6 '@vladfrangu/async_event_emitter': 2.4.6
discord-api-types: 0.38.13 discord-api-types: 0.38.37
magic-bytes.js: 1.10.0 magic-bytes.js: 1.10.0
tslib: 2.8.1 tslib: 2.8.1
undici: 6.21.3 undici: 6.21.3
'@discordjs/util@1.1.1': {} '@discordjs/util@1.2.0':
dependencies:
discord-api-types: 0.38.37
'@discordjs/ws@1.2.3': '@discordjs/ws@1.2.3':
dependencies: dependencies:
'@discordjs/collection': 2.1.1 '@discordjs/collection': 2.1.1
'@discordjs/rest': 2.5.1 '@discordjs/rest': 2.6.0
'@discordjs/util': 1.1.1 '@discordjs/util': 1.2.0
'@sapphire/async-queue': 1.5.5 '@sapphire/async-queue': 1.5.5
'@types/ws': 8.5.14 '@types/ws': 8.5.14
'@vladfrangu/async_event_emitter': 2.4.6 '@vladfrangu/async_event_emitter': 2.4.6
discord-api-types: 0.38.13 discord-api-types: 0.38.37
tslib: 2.8.1 tslib: 2.8.1
ws: 8.18.1 ws: 8.18.1
transitivePeerDependencies: transitivePeerDependencies:
@@ -3285,18 +3297,18 @@ snapshots:
dependencies: dependencies:
path-type: 4.0.0 path-type: 4.0.0
discord-api-types@0.38.13: {} discord-api-types@0.38.37: {}
discord.js@14.21.0: discord.js@14.25.1:
dependencies: dependencies:
'@discordjs/builders': 1.11.2 '@discordjs/builders': 1.13.1
'@discordjs/collection': 1.5.3 '@discordjs/collection': 1.5.3
'@discordjs/formatters': 0.6.1 '@discordjs/formatters': 0.6.2
'@discordjs/rest': 2.5.1 '@discordjs/rest': 2.6.0
'@discordjs/util': 1.1.1 '@discordjs/util': 1.2.0
'@discordjs/ws': 1.2.3 '@discordjs/ws': 1.2.3
'@sapphire/snowflake': 3.5.3 '@sapphire/snowflake': 3.5.3
discord-api-types: 0.38.13 discord-api-types: 0.38.37
fast-deep-equal: 3.1.3 fast-deep-equal: 3.1.3
lodash.snakecase: 4.1.1 lodash.snakecase: 4.1.1
magic-bytes.js: 1.10.0 magic-bytes.js: 1.10.0
+18 -103
View File
@@ -4,112 +4,27 @@
* @author Naomi Carrigan * @author Naomi Carrigan
*/ */
/** interface Channel {
* The channels to post standup reminders in.
*/
export const channels: Array<{
channelId: string; channelId: string;
roleId: string; roleId: string;
name: string; name: string;
}> = [ }
const nhcarriganMentorshipChannels: Array<Channel> = [
{ {
channelId: "1382093555228606484", channelId: "1400630073010163792",
name: "red-script", name: "accountability",
roleId: "1382091453987029144", roleId: "1400588705273745550",
},
{
channelId: "1382093583963656223",
name: "orange-bytes",
roleId: "1382091462707122186",
},
{
channelId: "1382093618017337574",
name: "yellow-packet",
roleId: "1382091466767208538",
},
{
channelId: "1382093654885138439",
name: "green-loop",
roleId: "1382091470877491364",
},
{
channelId: "1382093684925005935",
name: "blue-stack",
roleId: "1382091474560356393",
},
{
channelId: "1382093724200210522",
name: "purple-array",
roleId: "1382091477710012456",
},
{
channelId: "1382093753489162330",
name: "pink-protocol",
roleId: "1382091502255341568",
},
{
channelId: "1382093785973915820",
name: "cyan-branch",
roleId: "1382091520533856337",
},
{
channelId: "1382093811693387867",
name: "teal-cache",
roleId: "1382091525873336400",
},
{
channelId: "1382093843918225520",
name: "mint-syntax",
roleId: "1382091530428219603",
},
{
channelId: "1382093883722174605",
name: "lime-variable",
roleId: "1382091534538641458",
},
{
channelId: "1382093910259798046",
name: "rose-token",
roleId: "1382091538900979762",
},
{
channelId: "1382093973488799886",
name: "lavender-query",
roleId: "1382091542961066014",
},
{
channelId: "1382094002526097489",
name: "indigo-class",
roleId: "1382091547742568559",
},
{
channelId: "1382094051360116837",
name: "golden-index",
roleId: "1382091551982882936",
},
{
channelId: "1382094088739754096",
name: "silver-promise",
roleId: "1382091556613394443",
},
{
channelId: "1382094114467745912",
name: "bronze-thread",
roleId: "1382091560367292536",
},
{
channelId: "1382094146206044181",
name: "maroon-socket",
roleId: "1382091564498681907",
},
{
channelId: "1382094200211771522",
name: "violet-function",
roleId: "1382091568252719205",
},
{
channelId: "1382094311264616670",
name: "grey-database",
roleId: "1382091572602212622",
}, },
]; ];
const freeCodeCampHackathonChannels: Array<Channel> = [];
const dallasSoftwareDevelopersCohortChannels: Array<Channel> = [];
/**
* The channels to post standup reminders in.
*/
export const channels: Array<Channel> = [
...freeCodeCampHackathonChannels,
...dallasSoftwareDevelopersCohortChannels,
...nhcarriganMentorshipChannels,
];
+13 -1
View File
@@ -38,7 +38,8 @@ client.on(Events.ClientReady, () => {
}); });
}); });
client.on(Events.MessageCreate, (message) => { // eslint-disable-next-line @typescript-eslint/no-misused-promises -- sod off this is going away next month.
client.on(Events.MessageCreate, async(message) => {
if (!message.channel.isThread() || !message.inGuild()) { if (!message.channel.isThread() || !message.inGuild()) {
return; return;
} }
@@ -54,8 +55,19 @@ client.on(Events.MessageCreate, (message) => {
if (message.author.bot) { if (message.author.bot) {
return; return;
} }
const threadOwner = await message.channel.fetchOwner();
// Check if thread owner is Maribelle (to indicate it is progress thread)
if (threadOwner?.id !== "1386862413936328796") {
return;
}
if (!activeIds.includes(message.author.id)) { if (!activeIds.includes(message.author.id)) {
activeIds.push(message.author.id); activeIds.push(message.author.id);
await message.channel.send({
allowedMentions: {
parse: [],
},
content: `-# Thank you for your progress update, <@${message.author.id}>! Your participation for today has been recorded.`,
});
} }
}); });
+1 -5
View File
@@ -67,11 +67,7 @@ export const standup = async(
filtered.map(async(channel) => { filtered.map(async(channel) => {
const sent = await channel. const sent = await channel.
send({ allowedMentions: { send({ allowedMentions: {
roles: [ parse: [ "roles" ],
channels.find((c) => {
return c.channelId === channel.id;
})?.roleId ?? channel.guildId,
],
}, },
content: content:
`Good morning <@&${ `Good morning <@&${