Skip to content

Commit

Permalink
Merge pull request #60 from techstartucalgary/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
Axeloooo authored Feb 5, 2024
2 parents ca39b85 + 850b0ca commit fbe14d7
Show file tree
Hide file tree
Showing 37 changed files with 5,906 additions and 1,334 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,19 @@ on:
- dev

jobs:
lint:
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v3

- name: Install dependencies
run: cd backend && npm install

- name: Lint
run: cd backend && npm run lint

build:
runs-on: ubuntu-latest

Expand All @@ -19,3 +32,16 @@ jobs:

- name: Build
run: cd backend && npm run build

test:
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v3

- name: Install dependencies
run: cd backend && npm install

- name: Test
run: cd backend && npm test
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@ node_modules
dist
migrations
.DS_Store
.vscode
.vscode
coverage
29 changes: 15 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
- [Anfaal]() - Backend Developer
- [Ryan]() - Backend Developer
- [Alison]() - Backend Developer

## 👨‍💻 Tech Stack

- Frontend
Expand All @@ -51,12 +51,12 @@
![Node.js](https://img.shields.io/badge/Node.js-339933.svg?style=for-the-badge&logo=nodedotjs&logoColor=white)
![Prisma](https://img.shields.io/badge/Prisma-5a67d8.svg?style=for-the-badge&logo=Prisma&logoColor=white)
![MySQL](https://img.shields.io/badge/MySQL-3e6e93.svg?style=for-the-badge&logo=MySQL&logoColor=white)
![Zod](https://img.shields.io/badge/Zod-3E67B1.svg?style=for-the-badge&logo=Zod&logoColor=white)

- Cloud

![PlanetScale](https://img.shields.io/badge/PlanetScale-000000.svg?style=for-the-badge&logo=PlanetScale&logoColor=white)


## 🚀 Backend Documentation

All the code is located in the `backend/src` directory. The backend is written using [Node.js](https://nodejs.org/en/) and [Express](https://expressjs.com/).
Expand Down Expand Up @@ -187,39 +187,40 @@ datasource db {
npx prisma db push
```


# 🌟 Frontend Documentation

The frontend is crafted for iOS platforms, utilizing Swift and SwiftUI. The code is primarily housed in the `Rethread` directory. This section details the setup, development practices, and testing for the frontend environment.

## 🏃 Quickstart

1. **Clone the Repository**:
```bash
git clone [email protected]:techstartucalgary/fashion.git
```

```bash
git clone [email protected]:techstartucalgary/fashion.git
```

2. **Navigate to the Frontend Directory**:
```bash
cd Rethread
```

```bash
cd Rethread
```

3. **Open the Project in Xcode**:
Open the project file `.xcodeproj` in Xcode.
Open the project file `.xcodeproj` in Xcode.

4. **Run the Application**:
Select an iOS simulator or connected device in Xcode and click 'Run'.
Select an iOS simulator or connected device in Xcode and click 'Run'.

## 🛠️ Setup and Installation

1. **Install Xcode**:
Ensure you have Xcode installed on your macOS, available through the Mac App Store.
Ensure you have Xcode installed on your macOS, available through the Mac App Store.

2. **Update Swift and SwiftUI**:
Ensure you have the latest version of Swift and SwiftUI installed, as they are crucial for frontend development.
Ensure you have the latest version of Swift and SwiftUI installed, as they are crucial for frontend development.

3. **Verify the Installation**:
Open Xcode and check for Swift and SwiftUI updates in the preferences.
Open Xcode and check for Swift and SwiftUI updates in the preferences.

4. **Minimum iOS Version**: This app is built for `iOS 16` and above.

Expand Down
22 changes: 22 additions & 0 deletions backend/.eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"env": {
"es2021": true,
"node": true
},
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/recommended"
],
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": "latest",
"sourceType": "module"
},
"plugins": [
"@typescript-eslint"
],
"rules": {
"@typescript-eslint/no-unused-vars": "warn",
"@typescript-eslint/no-explicit-any": "warn"
}
}
2 changes: 2 additions & 0 deletions backend/.gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
node_modules
# Keep environment variables out of version control
.env
dist
coverage
15 changes: 15 additions & 0 deletions backend/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
version: "3"

services:
mysql:
image: mysql
environment:
MYSQL_ROOT_PASSWORD: root
MYSQL_DATABASE: rethread
ports:
- "3306:3306"
volumes:
- mysql:/var/lib/mysql

volumes:
mysql:
19 changes: 19 additions & 0 deletions backend/jest.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import type { Config } from "jest";

const config: Config = {
preset: "ts-jest",
testEnvironment: "node",
verbose: true,
globals: {
"ts-jest": {
tsconfig: "tsconfig.json",
},
},
testMatch: ["<rootDir>/dist/**/*.test.js"],
coverageReporters: ["html"],
collectCoverage: true,
collectCoverageFrom: ["<rootDir>/dist/src/**/*.js"],
coverageDirectory: "<rootDir>/coverage",
};

export default config;
Loading

0 comments on commit fbe14d7

Please sign in to comment.