Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
b0a2fcc
Add instructions for running the server
muhammadqzaih Mar 10, 2026
6b04880
Update README for local development instructions
muhammadqzaih Mar 10, 2026
445da02
update README to clarify project ownership
muhammadqzaih Mar 10, 2026
5c2a685
Merge branch 'addtests' of https://github.com/muhammadqzaih/learn-cic…
muhammadqzaih Mar 10, 2026
fddba53
Add CI workflow for testing on pull requests
muhammadqzaih Mar 10, 2026
e143513
Update CI workflow to check Node.js version instead of forcing failure
muhammadqzaih Mar 10, 2026
e386ee9
feat(tests): add vitest for testing and create auth tests
muhammadqzaih Mar 10, 2026
0e84dad
fix(ci): remove force failure step and ensure tests run after depende…
muhammadqzaih Mar 10, 2026
43b81fb
refactor(auth): simplify getAPIKey function to throw error on missing…
muhammadqzaih Mar 10, 2026
76a5a1e
feat(ci): update test step to include coverage reporting and add vite…
muhammadqzaih Mar 10, 2026
3157f5b
docs: update README to improve project description and add CI badge
muhammadqzaih Mar 10, 2026
a89b1ed
docs: remove redundant title from README
muhammadqzaih Mar 10, 2026
dd3ccd8
feat(ci): add style check step and integrate Prettier for code format…
muhammadqzaih Mar 10, 2026
dc09771
feat: add format:write script to package.json and ensure formatting c…
muhammadqzaih Mar 10, 2026
8274795
chore: update package.json to add eslint and jiti, and include lint s…
muhammadqzaih Mar 10, 2026
526b53c
style: format eslint.config.ts and package.json for improved readability
muhammadqzaih Mar 10, 2026
62d750a
chore: remove unused variable declaration in main.ts
muhammadqzaih Mar 10, 2026
e386112
feat: integrate eslint-plugin-security and update lint command to enf…
muhammadqzaih Mar 11, 2026
f99a279
fix: update users.ts to use crypto.randomBytes for hash generation an…
muhammadqzaih Mar 11, 2026
7e64087
feat: add CI/CD workflow for automated deployment on push to main branch
muhammadqzaih Mar 11, 2026
f0c8f9d
fix: ensure newline at end of file in cd.yml
muhammadqzaih Mar 11, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
node_modules
npm-debug.log
.git
.gitignore
dist
coverage
.env
25 changes: 25 additions & 0 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: cd

on:
push:
branches: [main]

jobs:
deploy:
name: Deploy
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 22

- name: Install dependencies
run: npm ci

- name: Build project
run: npm run build
46 changes: 46 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: ci

on:
pull_request:
branches: [main]

jobs:
tests:
name: Tests
runs-on: ubuntu-latest

steps:
- name: Check out code
uses: actions/checkout@v4

- name: Set up Node
uses: actions/setup-node@v4
with:
node-version: 22

- name: Install dependencies
run: npm ci

- name: Run Tests with Coverage
run: npm run test -- --coverage
style:
name: Style
runs-on: ubuntu-latest

steps:
- name: Check out code
uses: actions/checkout@v4

- name: Set up Node
uses: actions/setup-node@v4
with:
node-version: 22

- name: Install dependencies
run: npm ci

- name: Check Formatting
run: npm run format:check

- name: Run Linter
run: npm run lint -- --max-warnings=0
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
# learn-cicd-typescript-starter (Notely)

![CI Tests](https://github.com/muhammadqzih/learn-cicd-typescript-starter/actions/workflows/ci.yml/badge.svg)

MuhammadQzih's version of Boot.dev's Notely app
This repo contains the typescript starter code for the "Notely" application for the "Learn CICD" course on [Boot.dev](https://boot.dev).

## Local Development

Make sure you're on Node version 22+.

Create a `.env` file in the root of the project with the following contents:

```bash
Expand Down
16 changes: 16 additions & 0 deletions eslint.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
import js from "@eslint/js";
import globals from "globals";
import tseslint from "typescript-eslint";
import { defineConfig } from "eslint/config";
import pluginSecurity from "eslint-plugin-security";
export default defineConfig([
{ ignores: ["dist/**"] },
{
files: ["**/*.{js,mjs,cjs,ts,mts,cts}"],
plugins: { js },
extends: ["js/recommended"],
languageOptions: { globals: { ...globals.browser, ...globals.node } },
},
tseslint.configs.recommended,
pluginSecurity.configs.recommended,
]);
Loading