Skip to content

Commit 795ce9e

Browse files
committed
Merge branch 'development' into sriram-fix-owner-manage-all-permissions
2 parents 2a44364 + 54d0f6c commit 795ce9e

796 files changed

Lines changed: 45791 additions & 13572 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.

.babelrc

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
11
{
2-
"presets": ["react-app"]
2+
"presets": ["react-app"],
3+
"plugins": [
4+
"@babel/plugin-proposal-optional-chaining",
5+
"@babel/plugin-proposal-nullish-coalescing-operator"
6+
]
37
}

.circleci/config.yml

Lines changed: 0 additions & 154 deletions
This file was deleted.

.eslintignore

Lines changed: 17 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,26 @@
1-
*.png
2-
*.svg
3-
*.test.js
4-
*.test.jsx
5-
src/actions/**
6-
src/App.css
7-
src/config.json
8-
9-
src/index.js
10-
src/reducers/**
11-
src/styles.js
12-
src/__tests__/**
1+
# =======================================================================
2+
# ⚠️ DO NOT ADD NEW ENTRIES ⚠️
3+
# Only the files and folders listed below are allowed to be ignored.
4+
# This .gitignore is locked down to maintain consistency across the team.
5+
# To propose changes, please open a discussion or PR with justification.
6+
# =======================================================================
137

8+
# Ignore build folders
9+
/node_modules/
1410
/public/
1511
/build/
16-
/node_modules/
17-
src/components/App.jsx
18-
src/components/AutoReload/**
12+
13+
# Ignore test files inside /src/components
14+
src/components/BMDashboard/_tests_/BMDashboard.test.jsx
15+
src/components/Reports/PeopleReport/components/PeopleTasksPieChart.test.jsx
16+
17+
# Ignore folders in /src
1918
src/components/Badge/**
20-
src/components/common/**
19+
src/components/Dashboard/**
2120
src/components/Projects/**
22-
src/components/Reports/**
23-
src/components/SetupProfile/**
2421
src/components/SummaryManagement/**
25-
src/components/TaskEditSuggestions/**
2622
src/components/TeamMemberTasks/**
27-
src/components/Teams/**
28-
src/components/TeamLocations/**
29-
src/components/Timelog/**
23+
src/components/Teams/TeamMembersPopup.jsx
3024
src/components/UserManagement/**
3125
src/components/UserProfile/**
32-
src/components/Announcements/**
33-
src/components/EmailSubscribeForm/**
34-
src/components/Dashboard/**
26+
src/components/Announcements/index.jsx
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: Close PRs from Forks
2+
3+
on:
4+
pull_request_target:
5+
types:
6+
- opened
7+
- synchronize
8+
9+
jobs:
10+
check-fork:
11+
runs-on: ubuntu-latest
12+
permissions:
13+
pull-requests: write
14+
steps:
15+
- name: Check if PR is from a fork
16+
id: check
17+
run: |
18+
echo "PR head repo: ${{ github.event.pull_request.head.repo.full_name }}"
19+
echo "Base repo: ${{ github.event.repository.full_name }}"
20+
if [[ "${{ github.event.pull_request.head.repo.full_name }}" != "${{ github.event.repository.full_name }}" ]]; then
21+
echo "PR is from a fork"
22+
echo "is_fork=true" >> $GITHUB_ENV
23+
else
24+
echo "PR is not from a fork"
25+
echo "is_fork=false" >> $GITHUB_ENV
26+
fi
27+
28+
- name: Close PR and add comment
29+
if: env.is_fork == 'true'
30+
run: |
31+
PR_NUMBER=${{ github.event.pull_request.number }}
32+
GH_REPO=${{ github.repository }}
33+
echo "Closing PR #$PR_NUMBER in repository $GH_REPO"
34+
gh pr close \
35+
"$PR_NUMBER" \
36+
--repo "${{ github.repository }}" \
37+
--comment "This PR has been closed because PRs from forks are not allowed. Please create a branch directly off the origin repository and resubmit your PR."
38+
env:
39+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/deploy.yml

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
name: Build and Deploy
2+
on:
3+
push:
4+
branches:
5+
- main
6+
- development
7+
concurrency:
8+
group: Build and Deploy / ${{ github.ref_name == 'main' && 'Production' || 'Development' }}
9+
cancel-in-progress: true
10+
jobs:
11+
# Build
12+
build:
13+
name: Build
14+
strategy:
15+
matrix:
16+
environment: ${{ github.ref_name == 'main' && fromJson('["Production", "Beta"]') || fromJson('["Development"]') }}
17+
environment: ${{ matrix.environment }}
18+
runs-on: ubuntu-latest
19+
steps:
20+
- name: Checkout Repository
21+
uses: actions/checkout@v4
22+
- name: Setup Node.js
23+
uses: actions/setup-node@v4
24+
with:
25+
node-version: 14
26+
cache: 'npm'
27+
- name: Install Dependencies
28+
run: npm ci
29+
# We don't run tests here since we assume it's already done during PR process.
30+
# - name: Update Browser List
31+
# run: npx browserslist@latest --update-db
32+
- name: Build React App
33+
run: npm run build && cp build/index.html build/200.html
34+
env:
35+
NODE_ENV: ${{ github.ref_name == 'main' && 'production' || 'development' }}
36+
REACT_APP_APIENDPOINT: ${{ vars.REACT_APP_API_ENDPOINT }}
37+
GENERATE_SOURCEMAP: ${{ github.ref_name != 'main' }}
38+
- name: Upload Build Artifact
39+
uses: actions/upload-artifact@v4
40+
with:
41+
name: ${{ matrix.environment }} Build
42+
path: ./build
43+
# Deployment
44+
deployment-surge:
45+
name: Deploy to Surge
46+
needs: build
47+
runs-on: ubuntu-latest
48+
strategy:
49+
matrix:
50+
environment: ${{ github.ref_name == 'main' && fromJson('["Production", "Beta"]') || fromJson('["Development"]') }}
51+
environment: ${{ matrix.environment }}
52+
if: ${{ success() }}
53+
steps:
54+
- name: Download Build Artifact
55+
uses: actions/download-artifact@v4
56+
with:
57+
name: ${{ matrix.environment }} Build
58+
path: ./build
59+
- name: Deploy to Surge
60+
uses: dswistowski/surge-sh-action@v1
61+
with:
62+
domain: ${{ vars.SURGE_DOMAIN }}
63+
project: './build'
64+
login: ${{ secrets.SURGE_LOGIN }}
65+
token: ${{ secrets.SURGE_TOKEN }}

.github/workflows/lint.yml

Lines changed: 0 additions & 25 deletions
This file was deleted.

.github/workflows/node.js.yml

Lines changed: 0 additions & 29 deletions
This file was deleted.

0 commit comments

Comments
 (0)