Skip to content

Commit 88f91c5

Browse files
author
Gor Saribekyan
committed
first commit
0 parents  commit 88f91c5

664 files changed

Lines changed: 28779 additions & 0 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.editorconfig

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# EditorConfig is awesome: https://EditorConfig.org
2+
3+
# top-most EditorConfig file
4+
root = true
5+
6+
[*]
7+
indent_style = space
8+
indent_size = 2
9+
end_of_line = lf
10+
charset = utf-8
11+
trim_trailing_whitespace = false
12+
insert_final_newline = true

.env.example

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
NEXT_PUBLIC_ENV=
2+
NEXT_PUBLIC_INDEXING=
3+
NEXT_PUBLIC_MIXPANEL_TOKEN=
4+
NEXT_PUBLIC_DOMAIN=
5+
NEXT_PUBLIC_API_KEY=
6+
NEXT_PUBLIC_STRAPI=
7+
NEXTAUTH_SECRET=
8+
NEXT_PUBLIC_UXCAT_API=
9+
NEXTAUTH_URL=
10+
NEXT_PUBLIC_GA_MEASUREMENT_ID=
11+
12+
STRAPI_URL=
13+
14+
GOOGLE_CLIENT_ID=
15+
GOOGLE_CLIENT_SECRET=
16+
17+
LINKEDIN_CLIENT_ID=
18+
LINKEDIN_CLIENT_SECRET=
19+
20+
DISCORD_CLIENT_ID=
21+
DISCORD_CLIENT_SECRET=

.github/configs.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# Set to true to add reviewers to pull requests
2+
addReviewers: true
3+
4+
# Set to true to add assignees to pull requests
5+
addAssignees: false
6+
7+
# A list of reviewers to be added to pull requests (GitHub user name)
8+
# reviewers:
9+
10+
# - MaryWylde
11+
12+
# - Allow to merge the pull request only if all the reviewers approved
13+
# - Set too false to allow the pull request to be merged if one of the reviewers approved
14+
# - Default: true
15+
requireReviewersApproval: true
16+
17+
# A number of reviewers added to the pull request
18+
# Set 0 to add all the reviewers (default: 0)
19+
numberOfReviewers: 3
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: Run Cypress Tests
2+
3+
on:
4+
workflow_dispatch:
5+
6+
jobs:
7+
cypress-run:
8+
runs-on: ubuntu-latest
9+
10+
steps:
11+
- name: Checkout repository
12+
uses: actions/checkout@v4
13+
14+
- name: Use Node.js
15+
uses: actions/setup-node@v4
16+
with:
17+
node-version: 20
18+
19+
- name: Install dependencies
20+
run: yarn install
21+
22+
- name: Build app
23+
run: yarn build:staging
24+
env:
25+
NODE_ENV: production
26+
APP_ENV: staging
27+
28+
- name: Run Cypress tests
29+
uses: cypress-io/github-action@v6
30+
with:
31+
start: yarn start:staging
32+
wait-on: 'http://localhost:3005'
33+
wait-on-timeout: 300
34+
command: yarn cypress run
35+
env:
36+
NODE_ENV: production
37+
APP_ENV: staging
38+
CYPRESS_BASE_URL: http://localhost:3005

.github/workflows/main.yaml

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: CI Deployment
2+
3+
on:
4+
push:
5+
branches:
6+
- 'main'
7+
- 'dev'
8+
9+
jobs:
10+
11+
build:
12+
runs-on: ubuntu-latest
13+
14+
steps:
15+
- name: Checkout repository
16+
uses: actions/checkout@v2
17+
18+
- name: Set up Docker Buildx
19+
uses: docker/setup-buildx-action@v1
20+
21+
- name: 'Login to GitHub Container Registry'
22+
run: echo ${{secrets.REGISTRY_PASSWORD}} | docker login ${{secrets.REGISTRY_HOST}} --username ${{secrets.REGISTRY_USERNAME}} --password-stdin
23+
24+
25+
- name: Copy production env file
26+
if: github.ref == 'refs/heads/main'
27+
run: |
28+
echo ${{ secrets.ENV_PRODUCTION }} | base64 -d > .env
29+
30+
- name: Copy staging env file
31+
if: github.ref == 'refs/heads/dev'
32+
run: |
33+
echo ${{ secrets.ENV_STAGING }} | base64 -d > .env
34+
35+
36+
- name: Production Deploy
37+
if: github.ref == 'refs/heads/main'
38+
run: |
39+
docker build -t ${{ secrets.REGISTRY_HOST }}/keepsimple-next:prod .
40+
docker push ${{ secrets.REGISTRY_HOST }}/keepsimple-next:prod
41+
42+
- name: Staging Deploy
43+
if: github.ref == 'refs/heads/dev'
44+
run: |
45+
docker build -t ${{ secrets.REGISTRY_HOST }}/keepsimple-next:staging .
46+
docker push ${{ secrets.REGISTRY_HOST }}/keepsimple-next:staging
47+
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: Pull request type and issue check
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- dev # staging
7+
- main # production
8+
9+
jobs:
10+
type-check:
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- name: Checkout Code
15+
uses: actions/checkout@v2
16+
17+
- name: Setup Node.js
18+
uses: actions/setup-node@v2
19+
with:
20+
node-version: '18'
21+
22+
- name: Install Dependencies
23+
run: yarn install
24+
25+
- name: Type Check
26+
run: yarn tsc --noEmit

.gitignore

Lines changed: 117 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,117 @@
1+
# IDE
2+
.vscode
3+
.history
4+
.idea/
5+
6+
# Logs
7+
logs
8+
*.log
9+
npm-debug.log*
10+
yarn-debug.log*
11+
yarn-error.log*
12+
lerna-debug.log*
13+
14+
# Diagnostic reports (https://nodejs.org/api/report.html)
15+
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json
16+
17+
# Runtime data
18+
pids
19+
*.pid
20+
*.seed
21+
*.pid.lock
22+
23+
# Directory for instrumented libs generated by jscoverage/JSCover
24+
lib-cov
25+
26+
# Coverage directory used by tools like istanbul
27+
coverage
28+
*.lcov
29+
30+
# nyc test coverage
31+
.nyc_output
32+
33+
# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
34+
.grunt
35+
36+
# Bower dependency directory (https://bower.io/)
37+
bower_components
38+
39+
# node-waf configuration
40+
.lock-wscript
41+
42+
# Compiled binary addons (https://nodejs.org/api/addons.html)
43+
build/Release
44+
45+
# Dependency directories
46+
node_modules/
47+
jspm_packages/
48+
49+
# TypeScript v1 declaration files
50+
typings/
51+
52+
# TypeScript cache
53+
*.tsbuildinfo
54+
55+
# Optional npm cache directory
56+
.npm
57+
58+
# Optional eslint cache
59+
.eslintcache
60+
61+
# Microbundle cache
62+
.rpt2_cache/
63+
.rts2_cache_cjs/
64+
.rts2_cache_es/
65+
.rts2_cache_umd/
66+
67+
# Optional REPL history
68+
.node_repl_history
69+
70+
# Output of 'npm pack'
71+
*.tgz
72+
73+
# Yarn Integrity file
74+
.yarn-integrity
75+
76+
# dotenv environment variables file
77+
.env
78+
.env.test
79+
.env.local
80+
.env.production
81+
.env.staging
82+
83+
# parcel-bundler cache (https://parceljs.org/)
84+
.cache
85+
86+
# Next.js build output
87+
.next
88+
out
89+
90+
# Nuxt.js build / generate output
91+
.nuxt
92+
dist
93+
94+
# Gatsby files
95+
.cache/
96+
97+
# vuepress build output
98+
.vuepress/dist
99+
100+
# Serverless directories
101+
.serverless/
102+
103+
# FuseBox cache
104+
.fusebox/
105+
106+
# DynamoDB Local files
107+
.dynamodb/
108+
109+
# TernJS port file
110+
.tern-port
111+
112+
# OS files
113+
.DS_Store
114+
115+
# Package lock file
116+
package-lock.json
117+

.husky/pre-commit

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
npx lint-staged

.prettierrc.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
module.exports = {
2+
trailingComma: 'all',
3+
tabWidth: 2,
4+
semi: true,
5+
singleQuote: true,
6+
arrowParens: 'avoid',
7+
};

0 commit comments

Comments
 (0)