Skip to content

Commit

Permalink
Merge branch 'documentation_text' of https://github.com/cabrinenyona/…
Browse files Browse the repository at this point in the history
…parenting-app-ui into documentation_text
  • Loading branch information
cabrinenyona committed Aug 17, 2023
2 parents 162ca8f + f44ec56 commit e7e9dc7
Show file tree
Hide file tree
Showing 2,661 changed files with 272,967 additions and 153,051 deletions.
30 changes: 22 additions & 8 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
{
"root": true,
"ignorePatterns": ["projects/**/*"],
"ignorePatterns": ["packages/api/**/*", "packages/@idemsInternational/**/*"],
"plugins": ["jasmine"],
"env": { "jasmine": true },
"overrides": [
{
"files": ["*.ts"],
"parserOptions": {
"project": ["tsconfig.json", "e2e/tsconfig.json"],
"project": ["tsconfig.json"],
"createDefaultProgram": true
},
"extends": [
"plugin:@angular-eslint/ng-cli-compat",
"plugin:@angular-eslint/ng-cli-compat--formatting-add-on",
"plugin:@angular-eslint/recommended",
"plugin:@angular-eslint/template/process-inline-templates",
"prettier"
],
Expand Down Expand Up @@ -75,6 +76,7 @@
"@typescript-eslint/naming-convention": ["off"],
"@typescript-eslint/member-ordering": "off",
"@typescript-eslint/prefer-for-of": "warn",
"@typescript-eslint/sort-type-constituents": "off",
"@typescript-eslint/no-unused-expressions": "warn",
"@typescript-eslint/no-shadow": "warn",
"@angular-eslint/no-output-on-prefix": "warn",
Expand All @@ -85,23 +87,35 @@
"prefer-const": "off",
"quote-props": ["off", "as-needed"],
"prefer-arrow/prefer-arrow-functions": "off",
"jsdoc/newline-after-description": ["off"],
"no-underscore-dangle": "off",
"object-shorthand": "warn",
"no-var": "warn",
"no-console": "warn",
"no-console": "off",
"radix": "warn",
"eqeqeq": "warn",
"no-fallthrough": "warn",
"no-throw-literal": "warn",
"use-isnan": "warn",
"arrow-body-style": "off"
"arrow-body-style": "off",
"sort-keys": "off"
}
},
{
"files": ["*.html"],
"extends": ["plugin:@angular-eslint/template/recommended"],
"rules": {}
"rules": {
"@angular-eslint/template/eqeqeq": "warn"
}
},
{
"files": ["*.spec.ts"],
"extends": ["plugin:jasmine/recommended"],
"rules": {
"jasmine/no-focused-tests": 2,
"jasmine/new-line-before-expect": 0,
"jasmine/new-line-between-declarations": 0,
"jasmine/prefer-toHaveBeenCalledWith": 0
}
}
]
}
30 changes: 26 additions & 4 deletions .firebaserc
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
{
"projects": {
"default": "plh-teens-app1"
},
"targets": {
"plh-teens-app1": {
"hosting": {
Expand All @@ -13,11 +16,30 @@
],
"plh_za": [
"plh-za"
],
"early_family_math": [
"early-family-math"
],
"wash": [
"wash"
],
"perinatal": [
"perinatal"
],
"pfr": [
"parenting-for-respectability"
],
"debug": [
"idems-debug"
],
"plh_facilitator": [
"plh-facilitator"
],
"plh_kids": [
"plh-kids"
]
}
}
},
"projects": {
"default": "plh-teens-app1"
}
}
"etags": {}
}
26 changes: 18 additions & 8 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1,8 +1,18 @@
*.png filter=lfs diff=lfs merge=lfs -text
*.jpg filter=lfs diff=lfs merge=lfs -text
*.mp4 filter=lfs diff=lfs merge=lfs -text
*.mp3 filter=lfs diff=lfs merge=lfs -text
*.wav filter=lfs diff=lfs merge=lfs -text
*.gif filter=lfs diff=lfs merge=lfs -text
*.pdn filter=lfs diff=lfs merge=lfs -text
*.svg filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.jpg filter=lfs diff=lfs merge=lfs -text
*.mp4 filter=lfs diff=lfs merge=lfs -text
*.mp3 filter=lfs diff=lfs merge=lfs -text
*.wav filter=lfs diff=lfs merge=lfs -text
*.gif filter=lfs diff=lfs merge=lfs -text
*.pdn filter=lfs diff=lfs merge=lfs -text
*.svg filter=lfs diff=lfs merge=lfs -text
*.xlsx filter=lfs diff=lfs merge=lfs -text

*.json eol=crlf
*.ts eol=crlf
*.scss eol=crlf
*.html eol=crlf
*.js eol=crlf

*.sh text eol=lf
*.conf text eol=lf
22 changes: 22 additions & 0 deletions .github/ISSUE_TEMPLATE/glitchtip.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
---
name: GlitchTip report
about: Complete the form below to report crash report data
title: "[GlitchTip]"
labels: glitchtip
assignees: ''

---

**GlitchTip Link**
_url_

**Report txt**
```js

```

**Diagnosis (if known)**
_cause of error relating to codebase_

**Suggested fix (if known)**
_recommended means to fix_
3 changes: 1 addition & 2 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
PR Checklist

- [ ] - Latest `master` branch merged
- [ ] - PR title descriptive (can be used in release notes)
- [ ] PR title descriptive (can be used in release notes)

## Description

Expand Down
24 changes: 10 additions & 14 deletions .github/workflows/android-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
lfs: true
ref: "${{github.event.inputs.build_branch}}"
Expand All @@ -37,31 +37,27 @@ jobs:
run: |
echo ${{github.event.inputs.build_branch}} | sed 's/.*\///'
echo "DEPLOYMENT_NAME=$(echo ${{github.event.inputs.build_branch}} | sed 's/.*\///')" >> $GITHUB_ENV;
echo "SHA_SHORT=$(git rev-parse --short=6 HEAD)" >> $GITHUB_ENV
shell: bash
- name: Cache node modules
uses: actions/cache@v2
with:
path: ./.yarn/cache
# If cachebusting required (e.g. breaking yarn changes on update) change `v1` to another number
key: ${{ runner.os }}-node-modules-yarn-v1-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-v1-
- name: Setup node
uses: actions/setup-node@v1
uses: actions/setup-node@v3
with:
node-version: "16"
- name: Populate firebaseConfig.ts
node-version: 16
cache: 'yarn'
- name: Populate environment config
env:
FIREBASE_CONFIG_TS: ${{ secrets.FIREBASE_CONFIG_TS }}
run: echo $FIREBASE_CONFIG_TS > src/environments/firebaseConfig.ts
run: |
echo "export const GIT_SHA = \"$SHA_SHORT\";" > src/environments/sha.ts
echo $FIREBASE_CONFIG_TS > src/environments/firebaseConfig.ts
- name: Populate google-services.json
env:
GOOGLE_SERVICES_JSON: ${{ secrets.GOOGLE_SERVICES_JSON }}
run: echo $GOOGLE_SERVICES_JSON > android/app/google-services.json
- name: Install Dependencies
run: yarn install
- name: Set Deployment
run: yarn scripts deployment set $DEPLOYMENT_NAME
run: yarn workflow deployment set $DEPLOYMENT_NAME
- name: Build Angular Project
run: yarn build
- name: Sync Android Files
Expand Down
24 changes: 10 additions & 14 deletions .github/workflows/android-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
lfs: true
ref: "${{github.event.inputs.build_branch}}"
Expand All @@ -36,31 +36,27 @@ jobs:
run: |
echo ${{github.event.inputs.build_branch}} | sed 's/.*\///'
echo "DEPLOYMENT_NAME=$(echo ${{github.event.inputs.build_branch}} | sed 's/.*\///')" >> $GITHUB_ENV;
echo "SHA_SHORT=$(git rev-parse --short=6 HEAD)" >> $GITHUB_ENV
shell: bash
- name: Cache node modules
uses: actions/cache@v2
with:
path: ./.yarn/cache
# If cachebusting required (e.g. breaking yarn changes on update) change `v1` to another number
key: ${{ runner.os }}-node-modules-yarn-v1-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-v1-
- name: Setup node
uses: actions/setup-node@v1
uses: actions/setup-node@v3
with:
node-version: "16"
- name: Populate firebaseConfig.ts
node-version: 16
cache: 'yarn'
- name: Populate environment config
env:
FIREBASE_CONFIG_TS: ${{ secrets.FIREBASE_CONFIG_TS }}
run: echo $FIREBASE_CONFIG_TS > src/environments/firebaseConfig.ts
run: |
echo "export const GIT_SHA = \"$SHA_SHORT\";" > src/environments/sha.ts
echo $FIREBASE_CONFIG_TS > src/environments/firebaseConfig.ts
- name: Populate google-services.json
env:
GOOGLE_SERVICES_JSON: ${{ secrets.GOOGLE_SERVICES_JSON }}
run: echo $GOOGLE_SERVICES_JSON > android/app/google-services.json
- name: Install Dependencies
run: yarn install
- name: Set Deployment
run: yarn scripts deployment set $DEPLOYMENT_NAME
run: yarn workflow deployment set $DEPLOYMENT_NAME
- name: Build Angular Project
run: yarn build
- name: Sync Android Files
Expand Down
53 changes: 38 additions & 15 deletions .github/workflows/deployment-hosting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
build_and_deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
lfs: true
# Extract deployment name as the slug of target PR branch via string operators, e.g. /deployment/plh_tz -> plh_tz
Expand All @@ -23,30 +23,53 @@ jobs:
then echo "DEPLOYMENT_NAME=plh_global" >> $GITHUB_ENV; \
else echo "DEPLOYMENT_NAME=${GITHUB_REF##*/}" >> $GITHUB_ENV; \
fi;
echo "SHA_SHORT=$(git rev-parse --short=6 HEAD)" >> $GITHUB_ENV
shell: bash
- run: |
echo $GITHUB_REF
echo $DEPLOYMENT_NAME
echo $SHA_SHORT
- name: Node ${{ matrix.node-version }}
uses: actions/setup-node@v1
uses: actions/setup-node@v3
with:
node-version: 16.x
- name: Cache node modules
uses: actions/cache@v2
with:
path: ./.yarn/cache
# If cachebusting required (e.g. breaking yarn changes on update) change `v1` to another number
key: ${{ runner.os }}-node-modules-yarn-v1-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-v1-
- name: Populate firebaseConfig.ts
node-version: 16
cache: 'yarn'
- name: Populate environment config
env:
FIREBASE_CONFIG_TS: ${{ secrets.FIREBASE_CONFIG_TS }}
run: echo $FIREBASE_CONFIG_TS > src/environments/firebaseConfig.ts
run: |
echo "export const GIT_SHA = \"$SHA_SHORT\";" > src/environments/sha.ts
echo $FIREBASE_CONFIG_TS > src/environments/firebaseConfig.ts
- run: yarn install
- name: Set Scripts Deployment
run: yarn scripts deployment set $DEPLOYMENT_NAME
- run: yarn build
run: yarn workflow deployment set $DEPLOYMENT_NAME
### Generate and upload sourcemaps ###
- run: yarn build --configuration "production,glitchtip"
- name: set app version
run: echo "APP_VERSION=$(echo "$(cat package.json | jq -r '.version')")" >> $GITHUB_ENV
- name: Upload sourcemaps
run: |
npx @sentry/cli releases delete ${DEPLOYMENT_NAME}-${APP_VERSION}-${SHA_SHORT}
npx @sentry/cli releases files ${DEPLOYMENT_NAME}-${APP_VERSION}-${SHA_SHORT} upload-sourcemaps www/
env:
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN}}
SENTRY_URL: https://app.glitchtip.com/
SENTRY_ORG: idems
SENTRY_PROJECT: ${{env.DEPLOYMENT_NAME}}
continue-on-error: true
- name: Store sourcemaps artifact
uses: actions/upload-artifact@v3
with:
name: sourcemaps-$SHA_SHORT
path: www/*.map
# Only used for short-term debugging purposes or manual upload
retention-days: 30
- name: Remove sourcemaps from build
run: |
echo $(ls www)
find . -name "*.map" -type f -delete
echo $(ls www)
### Deploy ###
- uses: FirebaseExtended/action-hosting-deploy@v0
with:
repoToken: "${{ secrets.GITHUB_TOKEN }}"
Expand Down
Loading

0 comments on commit e7e9dc7

Please sign in to comment.