Skip to content

Addtests #132

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 19 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
3af6a2b
Remove package-lock.json and update API configuration to ensure port …
Ramz001 Aug 12, 2025
34eb44a
changes
Ramz001 Aug 13, 2025
8159f13
Merge pull request #1 from Ramz001/addtests
Ramz001 Aug 13, 2025
df97f82
Update API configuration to improve environment variable parsing and …
Ramz001 Aug 13, 2025
69c1490
Remove CI workflow configuration file from GitHub Actions.
Ramz001 Aug 13, 2025
7ee41e3
Update CI workflow to use Node.js version 22 and change failure comma…
Ramz001 Aug 13, 2025
f09cebb
Update package.json and pnpm-lock.yaml to add Vitest for testing and …
Ramz001 Aug 13, 2025
14ce828
Remove pnpm-lock.yaml and update CI workflow to use npm for dependenc…
Ramz001 Aug 13, 2025
c40eb57
Update package.json and package-lock.json to add @vitest/coverage-v8 …
Ramz001 Aug 13, 2025
d3657bb
Update CI workflow to modify test command for improved coverage repor…
Ramz001 Aug 13, 2025
d18b75b
Add CI badge to README for build status visibility
Ramz001 Aug 13, 2025
02e4447
Update package.json and package-lock.json to add Prettier for code fo…
Ramz001 Aug 14, 2025
d955d8b
Refactor CI workflow to improve style checks and add dependency insta…
Ramz001 Aug 14, 2025
ec04474
Fix CI workflow style job name for consistency
Ramz001 Aug 14, 2025
10cc5e8
Update package.json and package-lock.json to add new dependencies inc…
Ramz001 Aug 14, 2025
c6ca126
Enhance CI workflow by adding a linting step for code formatting chec…
Ramz001 Aug 14, 2025
6d59c1f
Update eslint configuration to include eslint-plugin-security for enh…
Ramz001 Aug 14, 2025
88a1036
Update CI workflow to enforce strict linting by setting max-warnings …
Ramz001 Aug 14, 2025
c49ba4a
Refactor generateRandomSHA256Hash function to use crypto.randomBytes …
Ramz001 Aug 15, 2025
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
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: Deployment

on:
push:
branches: [main]

jobs:
deploy:
name: Deploy
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: Build
run: npm run build
47 changes: 47 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
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: Running Tests
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 formating
run: npm run lint -- --max-warnings=0

- name: Check Styling
run: npm run format:check
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
![alt text goes here](https://github.com/Ramz001/learn-cicd-typescript-starter/actions/workflows/ci.yml/badge.svg)

# learn-cicd-typescript-starter (Notely)

This repo contains the typescript starter code for the "Notely" application for the "Learn CICD" course on [Boot.dev](https://boot.dev).
Expand All @@ -22,3 +24,5 @@ npm run dev
_This starts the server in non-database mode._ It will serve a simple webpage at `http://localhost:8080`.

You do _not_ need to set up a database or any interactivity on the webpage yet. Instructions for that will come later in the course!

Ramz's version of Boot.dev's Notely app.
22 changes: 22 additions & 0 deletions eslint.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
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([
{
files: ["**/*.{js,mjs,cjs,ts,mts,cts}"],
plugins: { js },
extends: ["js/recommended"],
rules: {
"no-undef": "warn",
},
},
{
files: ["**/*.{js,mjs,cjs,ts,mts,cts}"],
languageOptions: { globals: globals.node },
},
tseslint.configs.recommended,
pluginSecurity.configs.recommended,
]);
Loading