Skip to content

Commit

Permalink
Merge branch 'main' into fix-26092
Browse files Browse the repository at this point in the history
  • Loading branch information
shubham1206agra authored Sep 11, 2023
2 parents 1431ccf + 38a061b commit 88d1dd8
Show file tree
Hide file tree
Showing 168 changed files with 2,326 additions and 1,336 deletions.
1 change: 1 addition & 0 deletions .github/ISSUE_TEMPLATE/DesignDoc.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ labels: Daily, NewFeature
- [ ] Confirm that the doc has the minimum necessary number of reviews before proceeding
- [ ] Email `strategy@expensify.com` one last time to let them know the Design Doc is moving into the implementation phase
- [ ] Implement the changes
- [ ] Add regression tests so that QA can test your feature with every deploy ([instructions](https://stackoverflowteams.com/c/expensify/questions/363))
- [ ] Send out a follow up email to `strategy@expensify.com` once everything has been implemented and do a **Project Wrap-Up** retrospective that provides:
- Summary of what we accomplished with this project
- What went well?
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -207,10 +207,7 @@ function fetchTag(tag) {
console.log(`Running command: ${command}`);
execSync(command);
} catch (e) {
// This can happen if the tag was only created locally but does not exist in the remote. In this case, we'll fetch history of the staging branch instead
const command = `git fetch origin staging --no-tags --shallow-exclude=${previousPatchVersion}`;
console.log(`Running command: ${command}`);
execSync(command);
console.error(e);
}
}

Expand Down Expand Up @@ -301,13 +298,14 @@ function getValidMergedPRs(commits) {
* @returns {Promise<Array<Number>>} – Pull request numbers
*/
function getPullRequestsMergedBetween(fromTag, toTag) {
console.log(`Looking for commits made between ${fromTag} and ${toTag}...`);
return getCommitHistoryAsJSON(fromTag, toTag).then((commitList) => {
console.log(`Commits made between ${fromTag} and ${toTag}:`, commitList);

// Find which commit messages correspond to merged PR's
const pullRequestNumbers = getValidMergedPRs(commitList);
console.log(`List of pull requests merged between ${fromTag} and ${toTag}`, pullRequestNumbers);
return pullRequestNumbers;
return _.map(pullRequestNumbers, (prNum) => Number.parseInt(prNum, 10));
});
}

Expand Down
8 changes: 3 additions & 5 deletions .github/actions/javascript/getDeployPullRequestList/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -170,10 +170,7 @@ function fetchTag(tag) {
console.log(`Running command: ${command}`);
execSync(command);
} catch (e) {
// This can happen if the tag was only created locally but does not exist in the remote. In this case, we'll fetch history of the staging branch instead
const command = `git fetch origin staging --no-tags --shallow-exclude=${previousPatchVersion}`;
console.log(`Running command: ${command}`);
execSync(command);
console.error(e);
}
}

Expand Down Expand Up @@ -264,13 +261,14 @@ function getValidMergedPRs(commits) {
* @returns {Promise<Array<Number>>} – Pull request numbers
*/
function getPullRequestsMergedBetween(fromTag, toTag) {
console.log(`Looking for commits made between ${fromTag} and ${toTag}...`);
return getCommitHistoryAsJSON(fromTag, toTag).then((commitList) => {
console.log(`Commits made between ${fromTag} and ${toTag}:`, commitList);

// Find which commit messages correspond to merged PR's
const pullRequestNumbers = getValidMergedPRs(commitList);
console.log(`List of pull requests merged between ${fromTag} and ${toTag}`, pullRequestNumbers);
return pullRequestNumbers;
return _.map(pullRequestNumbers, (prNum) => Number.parseInt(prNum, 10));
});
}

Expand Down
8 changes: 3 additions & 5 deletions .github/libs/GitUtils.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,7 @@ function fetchTag(tag) {
console.log(`Running command: ${command}`);
execSync(command);
} catch (e) {
// This can happen if the tag was only created locally but does not exist in the remote. In this case, we'll fetch history of the staging branch instead
const command = `git fetch origin staging --no-tags --shallow-exclude=${previousPatchVersion}`;
console.log(`Running command: ${command}`);
execSync(command);
console.error(e);
}
}

Expand Down Expand Up @@ -116,13 +113,14 @@ function getValidMergedPRs(commits) {
* @returns {Promise<Array<Number>>} – Pull request numbers
*/
function getPullRequestsMergedBetween(fromTag, toTag) {
console.log(`Looking for commits made between ${fromTag} and ${toTag}...`);
return getCommitHistoryAsJSON(fromTag, toTag).then((commitList) => {
console.log(`Commits made between ${fromTag} and ${toTag}:`, commitList);

// Find which commit messages correspond to merged PR's
const pullRequestNumbers = getValidMergedPRs(commitList);
console.log(`List of pull requests merged between ${fromTag} and ${toTag}`, pullRequestNumbers);
return pullRequestNumbers;
return _.map(pullRequestNumbers, (prNum) => Number.parseInt(prNum, 10));
});
}

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ The GitHub workflows require a large list of secrets to deploy, notify and test
1. `LARGE_SECRET_PASSPHRASE` - decrypts secrets stored in various encrypted files stored in GitHub repository. To create updated versions of these encrypted files, refer to steps 1-4 of [this encrypted secrets help page](https://docs.github.com/en/actions/reference/encrypted-secrets#limits-for-secrets) using the `LARGE_SECRET_PASSPHRASE`.
1. `android/app/my-upload-key.keystore.gpg`
1. `android/app/android-fastlane-json-key.json.gpg`
1. `ios/chat_expensify_adhoc.mobileprovision.gpg`
1. `ios/expensify_chat_adhoc.mobileprovision.gpg`
1. `ios/chat_expensify_appstore.mobileprovision.gpg`
1. `ios/Certificates.p12.gpg`
1. `SLACK_WEBHOOK` - Sends Slack notifications via Slack WebHook https://expensify.slack.com/services/B01AX48D7MM
Expand Down
28 changes: 0 additions & 28 deletions .github/workflows/finishReleaseCycle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -119,31 +119,3 @@ jobs:
uses: Expensify/App/.github/actions/composite/announceFailedWorkflowInSlack@main
with:
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}

# Create a new StagingDeployCash for the next release cycle.
createNewStagingDeployCash:
runs-on: ubuntu-latest
needs: [updateStaging, createNewPatchVersion]
steps:
- uses: actions/checkout@v3
with:
ref: staging
token: ${{ secrets.OS_BOTIFY_TOKEN }}

# Create a local git tag so that GitUtils.getPullRequestsMergedBetween can use `git log` to generate a
# list of pull requests that were merged between this version tag and another.
# NOTE: This tag is only used locally and shouldn't be pushed to the remote.
# If it was pushed, that would trigger the staging deploy which is handled in a separate workflow (deploy.yml)
- name: Tag version
run: git tag ${{ needs.createNewPatchVersion.outputs.NEW_VERSION }}

- name: Create new StagingDeployCash
uses: Expensify/App/.github/actions/javascript/createOrUpdateStagingDeploy@main
with:
GITHUB_TOKEN: ${{ secrets.OS_BOTIFY_TOKEN }}
NPM_VERSION: ${{ needs.createNewPatchVersion.outputs.NEW_VERSION }}

- if: ${{ failure() }}
uses: Expensify/App/.github/actions/composite/announceFailedWorkflowInSlack@main
with:
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
2 changes: 1 addition & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:

- uses: Expensify/App/.github/actions/composite/setupNode@main

- name: Lint JavaScript with ESLint
- name: Lint JavaScript and Typescript with ESLint
run: npm run lint
env:
CI: true
Expand Down
19 changes: 19 additions & 0 deletions .github/workflows/platformDeploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,25 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.OS_BOTIFY_TOKEN }}

# Note: we're updating the checklist before running the deploys and assuming that it will succeed on at least one platform
deployChecklist:
name: Create or update deploy checklist
runs-on: ubuntu-latest
needs: validateActor
steps:
- uses: actions/checkout@v3
- uses: Expensify/App/.github/actions/composite/setupNode@main

- name: Set version
id: getVersion
run: echo "VERSION=$(npm run print-version --silent)" >> "$GITHUB_ENV"

- name: Create or update staging deploy
uses: Expensify/App/.github/actions/javascript/createOrUpdateStagingDeploy@main
with:
GITHUB_TOKEN: ${{ secrets.OS_BOTIFY_TOKEN }}
NPM_VERSION: ${{ steps.getVersion.outputs.VERSION }}

android:
name: Build and deploy Android
needs: validateActor
Expand Down
19 changes: 0 additions & 19 deletions .github/workflows/preDeploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -98,25 +98,6 @@ jobs:
# Force-update the remote staging branch
git push --force origin staging
# Create a local git tag on staging so that GitUtils.getPullRequestsMergedBetween can use `git log` to generate a
# list of pull requests that were merged between this version tag and another.
# NOTE: This tag is only used locally and shouldn't be pushed to the remote.
# If it was pushed, that would trigger the staging deploy which is handled in a separate workflow (deploy.yml)
- name: Tag staging
run: git tag ${{ needs.createNewVersion.outputs.NEW_VERSION }}

- name: Update StagingDeployCash
uses: Expensify/App/.github/actions/javascript/createOrUpdateStagingDeploy@main
with:
GITHUB_TOKEN: ${{ secrets.OS_BOTIFY_TOKEN }}
NPM_VERSION: ${{ needs.createNewVersion.outputs.NEW_VERSION }}

- name: Find open StagingDeployCash
id: getStagingDeployCash
run: echo "STAGING_DEPLOY_CASH=$(gh issue list --label StagingDeployCash --json number --jq '.[0].number')" >> "$GITHUB_OUTPUT"
env:
GITHUB_TOKEN: ${{ secrets.OS_BOTIFY_TOKEN }}

- if: ${{ failure() }}
uses: Expensify/App/.github/actions/composite/announceFailedWorkflowInSlack@main
with:
Expand Down
4 changes: 2 additions & 2 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -90,8 +90,8 @@ android {
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
multiDexEnabled rootProject.ext.multiDexEnabled
versionCode 1001036204
versionName "1.3.62-4"
versionCode 1001036700
versionName "1.3.67-0"
}

flavorDimensions "default"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,4 @@ developmentLogLevel = VERBOSE

# Notification Customization
notificationIcon = ic_notification
notificationAccentColor = #2EAAE2
notificationAccentColor = #03D47C
2 changes: 1 addition & 1 deletion android/app/src/main/assets/airshipconfig.properties
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ inProduction = true

# Notification Customization
notificationIcon = ic_notification
notificationAccentColor = #2EAAE2
notificationAccentColor = #03D47C
Binary file modified android/app/src/main/res/drawable-hdpi/ic_notification.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-mdpi/ic_notification.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-xhdpi/ic_notification.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-xxhdpi/ic_notification.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-xxxhdpi/ic_notification.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion android/app/src/main/res/values-large/orientation.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<bool name="portrait_only">false</bool>
<bool name="portrait_only">true</bool>
</resources>
2 changes: 1 addition & 1 deletion android/app/src/main/res/values-sw600dp/orientation.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<bool name="portrait_only">false</bool>
<bool name="portrait_only">true</bool>
</resources>
1 change: 1 addition & 0 deletions contributingGuides/FORMS.md
Original file line number Diff line number Diff line change
Expand Up @@ -274,6 +274,7 @@ Form.js will automatically provide the following props to any input with the inp
- onBlur: An onBlur handler that calls validate.
- onTouched: An onTouched handler that marks the input as touched.
- onInputChange: An onChange handler that saves draft values and calls validate for that input (inputA). Passing an inputID as a second param allows inputA to manipulate the input value of the provided inputID (inputB).
- onFocus: An onFocus handler that marks the input as focused.

## Dynamic Form Inputs

Expand Down
5 changes: 4 additions & 1 deletion docs/articles/request-money/Request-and-Split-Bills.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,10 @@ These two features ensure you can live in the moment and settle up afterward.

# How to Request Money
- Select the Green **+** button and choose **Request Money**
- Enter the amount **$** they owe and click **Next**
- Select the relevant option:
- **Manual:** Enter the merchant and amount manually.
- **Scan:** Take a photo of the receipt to have the merchant and amount auto-filled.
- **Distance:** Enter the details of your trip, plus any stops along the way, and the mileage and amount will be automatically calculated.
- Search for the user or enter their email!
- Enter a reason for the request (optional)
- Click **Request!**
Expand Down
Binary file modified docs/assets/images/insights-chart.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 5 additions & 5 deletions fastlane/Fastfile
Original file line number Diff line number Diff line change
Expand Up @@ -224,11 +224,11 @@ platform :ios do
contact_phone: ENV["APPLE_CONTACT_PHONE"],
demo_account_name: ENV["APPLE_DEMO_EMAIL"],
demo_account_password: ENV["APPLE_DEMO_PASSWORD"],
notes: "1. Log into the Expensify app using the provided email
2. Now, you have to log in to this gmail account on https://mail.google.com/ so you can retrieve a One-Time-Password
3. To log in to the gmail account, use the password above (That's NOT a password for the Expensify app but for the Gmail account)
4. At the Gmail inbox, you should have received a one-time 6 digit magic code
5. Use that to sign in"
notes: "1. In the Expensify app, enter the email 'appletest.expensify@proton.me'. This will trigger a sign-in link to be sent to 'appletest.expensify@proton.me'
2. Navigate to https://account.proton.me/login, log into Proton Mail using 'appletest.expensify@proton.me' as email and the password associated with 'appletest.expensify@proton.me', provided above
3. Once logged into Proton Mail, navigate to your inbox and locate the email triggered in step 1. The email subject should be 'Your magic sign-in link for Expensify'
4. Open the email and copy the 6-digit sign-in code provided within
5. Return to the Expensify app and enter the copied 6-digit code in the designated login field"
}
)
rescue Exception => e
Expand Down
Binary file modified ios/Certificates.p12.gpg
Binary file not shown.
8 changes: 4 additions & 4 deletions ios/NewExpensify/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.3.62</string>
<string>1.3.67</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleURLTypes</key>
Expand All @@ -40,7 +40,7 @@
</dict>
</array>
<key>CFBundleVersion</key>
<string>1.3.62.4</string>
<string>1.3.67.0</string>
<key>ITSAppUsesNonExemptEncryption</key>
<false/>
<key>LSApplicationQueriesSchemes</key>
Expand Down Expand Up @@ -108,6 +108,8 @@
<array>
<string>armv7</string>
</array>
<key>UIRequiresFullScreen</key>
<true/>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
Expand All @@ -117,8 +119,6 @@
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
<string>UIInterfaceOrientationLandscapeRight</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
</array>
<key>UIUserInterfaceStyle</key>
<string>Dark</string>
Expand Down
4 changes: 2 additions & 2 deletions ios/NewExpensifyTests/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@
<key>CFBundlePackageType</key>
<string>BNDL</string>
<key>CFBundleShortVersionString</key>
<string>1.3.62</string>
<string>1.3.67</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>1.3.62.4</string>
<string>1.3.67.0</string>
</dict>
</plist>
4 changes: 2 additions & 2 deletions ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -591,7 +591,7 @@ PODS:
- React-Core
- react-native-pager-view (6.2.0):
- React-Core
- react-native-pdf (6.6.2):
- react-native-pdf (6.7.1):
- React-Core
- react-native-performance (4.0.0):
- React-Core
Expand Down Expand Up @@ -1254,7 +1254,7 @@ SPEC CHECKSUMS:
react-native-key-command: c2645ec01eb1fa664606c09480c05cb4220ef67b
react-native-netinfo: ccbe1085dffd16592791d550189772e13bf479e2
react-native-pager-view: 0ccb8bf60e2ebd38b1f3669fa3650ecce81db2df
react-native-pdf: 33c622cbdf776a649929e8b9d1ce2d313347c4fa
react-native-pdf: 7c0e91ada997bac8bac3bb5bea5b6b81f5a3caae
react-native-performance: 224bd53e6a835fda4353302cf891d088a0af7406
react-native-plaid-link-sdk: 9eb0f71dad94b3bdde649c7a384cba93024af46c
react-native-quick-sqlite: bcc7a7a250a40222f18913a97cd356bf82d0a6c4
Expand Down
Binary file removed ios/chat_expensify_adhoc.mobileprovision.gpg
Binary file not shown.
Binary file modified ios/chat_expensify_appstore.mobileprovision.gpg
Binary file not shown.
Binary file modified ios/expensify_chat_adhoc.mobileprovision.gpg
Binary file not shown.
Binary file removed ios/expensify_chat_dev.mobileprovision.gpg
Binary file not shown.
Loading

0 comments on commit 88d1dd8

Please sign in to comment.