Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
10 changes: 1 addition & 9 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,6 @@ This is a checklist for PR authors. Please make sure to complete all tasks and c
- [ ] iOS: Native
- [ ] iOS: mWeb Safari
- [ ] MacOS: Chrome / Safari
- [ ] MacOS: Desktop
- [ ] I verified there are no console errors (if there's a console error not related to the PR, report it or open an issue for it to be fixed)
- [ ] I verified there are no new alerts related to the `canBeMissing` param for `useOnyx`
- [ ] I followed proper code patterns (see [Reviewing the code](https://github.com/Expensify/App/blob/main/contributingGuides/PR_REVIEW_GUIDELINES.md#reviewing-the-code))
Expand Down Expand Up @@ -157,11 +156,4 @@ This is a checklist for PR authors. Please make sure to complete all tasks and c

<!-- add screenshots or videos here -->

</details>

<details>
<summary>MacOS: Desktop</summary>

<!-- add screenshots or videos here -->

</details>
</details>
26 changes: 2 additions & 24 deletions .github/actions/composite/setupNode/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,6 @@ inputs:
description: "Indicates if node is set up for hybrid app"
required: false
default: 'false'
IS_DESKTOP_BUILD:
description: "Indicates if node is set up for desktop app"
required: false
default: 'false'

outputs:
cache-hit:
Expand All @@ -27,9 +23,7 @@ runs:
with:
node-version-file: '.nvmrc'
cache: npm
cache-dependency-path: |
normalized-package-lock.json
desktop/package-lock.json
cache-dependency-path: normalized-package-lock.json

- id: cache-node-modules
# v4
Expand All @@ -46,14 +40,6 @@ runs:
path: Mobile-Expensify/node_modules
key: ${{ runner.os }}-node-modules-${{ hashFiles('Mobile-Expensify/package-lock.json', 'Mobile-Expensify/patches/**') }}

- id: cache-desktop-node-modules
if: inputs.IS_DESKTOP_BUILD == 'true'
# v4
uses: actions/cache@1bd1e32a3bdc45362d1e726936510720a7c30a57
with:
path: desktop/node_modules
key: ${{ runner.os }}-desktop-node-modules-${{ hashFiles('desktop/package-lock.json', 'desktop/patches/**') }}

- name: Remove ND node_modules if needed for hybrid app build
if: inputs.IS_HYBRID_BUILD == 'true' && steps.cache-node-modules.outputs.cache-hit == 'true' && steps.cache-old-dot-node-modules.outputs.cache-hit != 'true'
shell: bash
Expand All @@ -65,12 +51,4 @@ runs:
with:
timeout_minutes: 30
max_attempts: 3
command: npm ci

- name: Install node packages for desktop submodule
if: inputs.IS_DESKTOP_BUILD == 'true' && steps.cache-desktop-node-modules.outputs.cache-hit != 'true'
uses: nick-fields/retry@3f757583fb1b1f940bc8ef4bf4734c8dc02a5847
with:
timeout_minutes: 30
max_attempts: 3
command: cd desktop && npm ci
command: npm ci
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,6 @@ inputs:
ANDROID:
description: "Android job result ('success', 'failure', 'cancelled', or 'skipped')"
required: true
DESKTOP:
description: "Desktop job result ('success', 'failure', 'cancelled', or 'skipped')"
required: true
IOS:
description: "iOS job result ('success', 'failure', 'cancelled', or 'skipped')"
required: true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12840,7 +12840,6 @@ async function run() {
const isProd = ActionUtils.getJSONInput('IS_PRODUCTION_DEPLOY', { required: true });
const version = core.getInput('DEPLOY_VERSION', { required: true });
const androidResult = getDeployTableMessage(core.getInput('ANDROID', { required: true }));
const desktopResult = getDeployTableMessage(core.getInput('DESKTOP', { required: true }));
const iOSResult = getDeployTableMessage(core.getInput('IOS', { required: true }));
const webResult = getDeployTableMessage(core.getInput('WEB', { required: true }));
const date = core.getInput('DATE');
Expand All @@ -12852,7 +12851,7 @@ async function run() {
message += `on ${date}`;
}
message += `🚀`;
message += `\n\nplatform | result\n---|---\n🖥 desktop 🖥|${desktopResult}`;
message += `\n\nplatform | result\n---|---`;
message += `\n🕸 web 🕸|${webResult}`;
message += `\n🤖 android 🤖|${androidResult}\n🍎 iOS 🍎|${iOSResult}`;
if (note) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,6 @@ async function run() {
const version = core.getInput('DEPLOY_VERSION', {required: true});

const androidResult = getDeployTableMessage(core.getInput('ANDROID', {required: true}) as PlatformResult);
const desktopResult = getDeployTableMessage(core.getInput('DESKTOP', {required: true}) as PlatformResult);
const iOSResult = getDeployTableMessage(core.getInput('IOS', {required: true}) as PlatformResult);
const webResult = getDeployTableMessage(core.getInput('WEB', {required: true}) as PlatformResult);

Expand All @@ -117,7 +116,7 @@ async function run() {
message += `on ${date}`;
}
message += `🚀`;
message += `\n\nplatform | result\n---|---\n🖥 desktop 🖥|${desktopResult}`;
message += `\n\nplatform | result\n---|---`;
message += `\n🕸 web 🕸|${webResult}`;
message += `\n🤖 android 🤖|${androidResult}\n🍎 iOS 🍎|${iOSResult}`;

Expand Down
6 changes: 0 additions & 6 deletions .github/actions/javascript/postTestBuildComment/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,6 @@ inputs:
ANDROID:
description: "Android job result ('success', 'failure', 'cancelled', or 'skipped')"
required: false
DESKTOP:
description: "Desktop job result ('success', 'failure', 'cancelled', or 'skipped')"
required: false
IOS:
description: "iOS job result ('success', 'failure', 'cancelled', or 'skipped')"
required: false
Expand All @@ -28,9 +25,6 @@ inputs:
ANDROID_LINK:
description: "Link for the Android build"
required: false
DESKTOP_LINK:
description: "Link for the desktop build"
required: false
IOS_LINK:
description: "Link for the iOS build"
required: false
Expand Down
17 changes: 8 additions & 9 deletions .github/actions/javascript/postTestBuildComment/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -11585,12 +11585,11 @@ const github_1 = __nccwpck_require__(5438);
const CONST_1 = __importDefault(__nccwpck_require__(9873));
const GithubUtils_1 = __importDefault(__nccwpck_require__(9296));
function getTestBuildMessage(appPr, mobileExpensifyPr) {
const inputs = ['ANDROID', 'DESKTOP', 'IOS', 'WEB'];
const inputs = ['ANDROID', 'IOS', 'WEB'];
const names = {
[inputs[0]]: 'Android',
[inputs[1]]: 'Desktop',
[inputs[2]]: 'iOS',
[inputs[3]]: 'Web',
[inputs[1]]: 'iOS',
[inputs[2]]: 'Web',
};
const result = inputs.reduce((acc, platform) => {
const input = core.getInput(platform, { required: false });
Expand Down Expand Up @@ -11619,17 +11618,17 @@ function getTestBuildMessage(appPr, mobileExpensifyPr) {
};
return acc;
}, {});
const message = `:test_tube::test_tube: Use the links below to test this adhoc build on Android, iOS${appPr ? ', Desktop, and Web' : ''}. Happy testing! :test_tube::test_tube:
const message = `:test_tube::test_tube: Use the links below to test this adhoc build on Android, iOS${appPr ? ', and Web' : ''}. Happy testing! :test_tube::test_tube:
Built from${appPr ? ` App PR Expensify/App#${appPr}` : ''}${mobileExpensifyPr ? ` Mobile-Expensify PR Expensify/Mobile-Expensify#${mobileExpensifyPr}` : ''}.
| Android :robot: | iOS :apple: |
| ------------- | ------------- |
| ${result.ANDROID.link} | ${result.IOS.link} |
| ${result.ANDROID.qrCode} | ${result.IOS.qrCode} |

| Desktop :computer: | Web :spider_web: |
| ------------- | ------------- |
| ${result.DESKTOP.link} | ${result.WEB.link} |
| ${result.DESKTOP.qrCode} | ${result.WEB.qrCode} |
| Web :spider_web: |
| ------------- |
| ${result.WEB.link} |
| ${result.WEB.qrCode} |

---

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,11 @@ import CONST from '@github/libs/CONST';
import GithubUtils from '@github/libs/GithubUtils';

function getTestBuildMessage(appPr?: number, mobileExpensifyPr?: number): string {
const inputs = ['ANDROID', 'DESKTOP', 'IOS', 'WEB'] as const;
const inputs = ['ANDROID', 'IOS', 'WEB'] as const;
const names = {
[inputs[0]]: 'Android',
[inputs[1]]: 'Desktop',
[inputs[2]]: 'iOS',
[inputs[3]]: 'Web',
[inputs[1]]: 'iOS',
[inputs[2]]: 'Web',
};

const result = inputs.reduce(
Expand Down Expand Up @@ -47,17 +46,17 @@ function getTestBuildMessage(appPr?: number, mobileExpensifyPr?: number): string
{} as Record<TupleToUnion<typeof inputs>, {link: string; qrCode: string}>,
);

const message = `:test_tube::test_tube: Use the links below to test this adhoc build on Android, iOS${appPr ? ', Desktop, and Web' : ''}. Happy testing! :test_tube::test_tube:
const message = `:test_tube::test_tube: Use the links below to test this adhoc build on Android, iOS${appPr ? ', and Web' : ''}. Happy testing! :test_tube::test_tube:
Built from${appPr ? ` App PR Expensify/App#${appPr}` : ''}${mobileExpensifyPr ? ` Mobile-Expensify PR Expensify/Mobile-Expensify#${mobileExpensifyPr}` : ''}.
| Android :robot: | iOS :apple: |
| ------------- | ------------- |
| ${result.ANDROID.link} | ${result.IOS.link} |
| ${result.ANDROID.qrCode} | ${result.IOS.qrCode} |

| Desktop :computer: | Web :spider_web: |
| ------------- | ------------- |
| ${result.DESKTOP.link} | ${result.WEB.link} |
| ${result.DESKTOP.qrCode} | ${result.WEB.qrCode} |
| Web :spider_web: |
| ------------- |
| ${result.WEB.link} |
| ${result.WEB.qrCode} |

---

Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/checkE2ETestCode.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@ jobs:

- name: Setup Node
uses: ./.github/actions/composite/setupNode
with:
IS_DESKTOP_BUILD: 'true'

- name: Verify e2e tests compile correctly
run: npm run e2e-test-runner-build
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/checkSVGCompression.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,6 @@ jobs:

- name: Setup Node
uses: ./.github/actions/composite/setupNode
with:
IS_DESKTOP_BUILD: true

- name: Compress SVG check
uses: ./.github/actions/javascript/checkSVGCompression
80 changes: 5 additions & 75 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -286,70 +286,6 @@ jobs:
GITHUB_TOKEN: ${{ github.token }}
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK }}

desktop:
name: Build and deploy Desktop
needs: prep
runs-on: macos-14-large
steps:
- name: Checkout
# v4
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608

- name: Setup Node
uses: ./.github/actions/composite/setupNode
with:
IS_DESKTOP_BUILD: true

# v6.0.0
- name: Setup Python for node-gyp
id: setup-python
uses: actions/setup-python@18566f86b301499665bd3eb1a2247e0849c64fa5
with:
python-version: '3.12'
cache: 'pip'
cache-dependency-path: desktop/requirements.txt

- name: Ensure setuptools for node-gyp
run: pip install --upgrade -r desktop/requirements.txt

- name: Load Desktop credentials from 1Password
id: load-credentials
# v2
uses: 1password/load-secrets-action@581a835fb51b8e7ec56b71cf2ffddd7e68bb25e0
with:
export-env: false
env:
OP_SERVICE_ACCOUNT_TOKEN: ${{ secrets.OP_SERVICE_ACCOUNT_TOKEN }}
DESKTOP_CERTIFICATE_BASE64: "op://${{ vars.OP_VAULT }}/Desktop Certificates.p12/CSC_LINK"
DESKTOP_CERTIFICATE_PASSWORD: "op://${{ vars.OP_VAULT }}/Desktop Certificates.p12/CSC_KEY_PASSWORD"

- name: Build desktop app
run: ${{ github.ref == 'refs/heads/production' && 'npm run desktop-build' || 'npm run desktop-build-staging' }}
env:
CSC_LINK: ${{ steps.load-credentials.outputs.DESKTOP_CERTIFICATE_BASE64 }}
CSC_KEY_PASSWORD: ${{ steps.load-credentials.outputs.DESKTOP_CERTIFICATE_PASSWORD }}
APPLE_ID: ${{ secrets.APPLE_ID }}
APPLE_TEAM_ID: ${{ secrets.APPLE_TEAM_ID }}
APPLE_APP_SPECIFIC_PASSWORD: ${{ secrets.APPLE_ID_PASSWORD }}
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
GCP_GEOLOCATION_API_KEY: ${{ secrets.GCP_GEOLOCATION_API_KEY_PRODUCTION }}
S3_BUCKET: ${{ github.ref == 'refs/heads/production' && vars.PRODUCTION_S3_BUCKET || vars.STAGING_S3_BUCKET }}

- name: Upload desktop sourcemaps artifact
# v4
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02
with:
name: desktop-sourcemaps-artifact
path: ./desktop/dist/www/merged-source-map.js.map

- name: Upload desktop build artifact
# v4
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02
with:
name: desktop-build-artifact
path: ./desktop-build/NewExpensify.dmg

ios:
name: Build and deploy iOS HybridApp
needs: prep
Expand Down Expand Up @@ -613,7 +549,7 @@ jobs:
name: Post a Slack message when any platform fails to build or deploy
runs-on: ubuntu-latest
if: ${{ failure() }}
needs: [android, desktop, ios, web]
needs: [android, ios, web]
steps:
- name: Checkout
# v4
Expand All @@ -629,7 +565,7 @@ jobs:
outputs:
IS_AT_LEAST_ONE_PLATFORM_DEPLOYED: ${{ steps.checkDeploymentSuccessOnAtLeastOnePlatform.outputs.IS_AT_LEAST_ONE_PLATFORM_DEPLOYED }}
IS_ALL_PLATFORMS_DEPLOYED: ${{ steps.checkDeploymentSuccessOnAllPlatforms.outputs.IS_ALL_PLATFORMS_DEPLOYED }}
needs: [android, desktop, ios, web]
needs: [android, ios, web]
if: ${{ always() }}
steps:
- name: Check deployment success on at least one platform
Expand All @@ -638,7 +574,6 @@ jobs:
isAtLeastOnePlatformDeployed="false"
if [ "${{ needs.iOS.result }}" == "success" ] || \
[ "${{ needs.android.result }}" == "success" ] || \
[ "${{ needs.desktop.result }}" == "success" ] || \
[ "${{ needs.web.result }}" == "success" ]; then
isAtLeastOnePlatformDeployed="true"
fi
Expand All @@ -651,7 +586,6 @@ jobs:
isAllPlatformsDeployed="false"
if [ "${{ needs.iOS.result }}" == "success" ] && \
[ "${{ needs.android.result }}" == "success" ] && \
[ "${{ needs.desktop.result }}" == "success" ] && \
[ "${{ needs.web.result }}" == "success" ]; then
isAllPlatformsDeployed="true"
fi
Expand Down Expand Up @@ -699,10 +633,9 @@ jobs:
env:
GITHUB_TOKEN: ${{ github.token }}

- name: Rename web and desktop sourcemaps artifacts before assets upload in order to have unique ReleaseAsset.name
- name: Rename web sourcemaps artifacts before assets upload in order to have unique ReleaseAsset.name
continue-on-error: true
run: |
mv ./desktop-sourcemaps-artifact/merged-source-map.js.map ./desktop-sourcemaps-artifact/desktop-merged-source-map.js.map
mv ./web-sourcemaps-artifact/merged-source-map.js.map ./web-sourcemaps-artifact/web-merged-source-map.js.map

- name: Upload artifacts to GitHub Release
Expand All @@ -713,8 +646,6 @@ jobs:
./android-build-artifact/Expensify-release.aab#android.aab
./android-apk-artifact/Expensify.apk#android.apk
./android-sourcemap-artifact/index.android.bundle.map#android-sourcemap.js.map
./desktop-sourcemaps-artifact/desktop-merged-source-map.js.map#desktop-sourcemap.js.map
./desktop-build-artifact/NewExpensify.dmg#desktop.dmg
./ios-build-artifact/Expensify.ipa#ios.ipa
./ios-sourcemap-artifact/main.jsbundle.map#ios-sourcemap.js.map
./web-sourcemaps-artifact/web-merged-source-map.js.map#web-sourcemap.js.map
Expand Down Expand Up @@ -774,7 +705,7 @@ jobs:
name: Post a Slack message when all platforms deploy successfully
runs-on: ubuntu-latest
if: ${{ always() && fromJSON(needs.checkDeploymentSuccess.outputs.IS_ALL_PLATFORMS_DEPLOYED) }}
needs: [prep, android, desktop, ios, web, checkDeploymentSuccess, createRelease]
needs: [prep, android, ios, web, checkDeploymentSuccess, createRelease]
steps:
- name: 'Announces the deploy in the #announce Slack room'
# v3
Expand Down Expand Up @@ -831,12 +762,11 @@ jobs:
postGithubComments:
uses: ./.github/workflows/postDeployComments.yml
if: ${{ always() && fromJSON(needs.checkDeploymentSuccess.outputs.IS_AT_LEAST_ONE_PLATFORM_DEPLOYED) }}
needs: [prep, android, desktop, ios, web, checkDeploymentSuccess, createRelease]
needs: [prep, android, ios, web, checkDeploymentSuccess, createRelease]
secrets: inherit
with:
version: ${{ needs.prep.outputs.APP_VERSION }}
env: ${{ github.ref == 'refs/heads/production' && 'production' || 'staging' }}
android: ${{ needs.android.result }}
ios: ${{ needs.ios.result }}
web: ${{ needs.web.result }}
desktop: ${{ needs.desktop.result }}
2 changes: 0 additions & 2 deletions .github/workflows/e2ePerformanceTests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -113,8 +113,6 @@ jobs:

- name: Setup Node
uses: ./.github/actions/composite/setupNode
with:
IS_DESKTOP_BUILD: 'true'

- name: Make zip directory for everything to send to AWS Device Farm
run: mkdir zip
Expand Down
Loading
Loading