Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chore/merged mercari GitHub go jek ocbc rakuten #24

Open
wants to merge 39 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
13eb1ee
OCBC code challenge
khalid64927 Mar 4, 2022
44d0526
removed dynatrace
khalid64927 Jun 3, 2022
fb72c85
Khalid/codechallenge/ocbc mock kaspresso (#9)
khalid64927 Jul 15, 2022
87e5c62
Feat: Added Danger (#18) (#19)
khalid64927 Sep 3, 2022
d852180
Chore: added sonar properties file
khalid64927 Sep 3, 2022
21adb43
Add timeline feature and refactored
khalid64927 Aug 14, 2023
396a5a8
Add: working code for feature
khalid64927 Aug 15, 2023
739bf39
Add: spotless applied
khalid64927 Aug 15, 2023
4c7bdf8
Added Test cases in viewmodels
khalid64927 Aug 16, 2023
2fe1eba
Fix spotlessApply run
khalid64927 Aug 16, 2023
0241bbd
Add PNG artifact for Demo
khalid64927 Aug 16, 2023
51f7920
Add readme
khalid64927 Aug 16, 2023
8b1d696
Added artifactes in relase folder
khalid64927 Aug 16, 2023
792865c
Added dependecy update
khalid64927 Aug 19, 2023
b4063ed
Updated workflow
khalid64927 Aug 19, 2023
1c042c1
Updated workflow
khalid64927 Aug 19, 2023
8d7e7fe
Update build.yml
khalid64927 Aug 19, 2023
45e0f2d
Update build.yml
khalid64927 Aug 19, 2023
34a4f6c
Update build.yml
khalid64927 Aug 19, 2023
9c510ac
Update gradle.properties
khalid64927 Aug 19, 2023
d7cd71b
Chore: removed commented code
khalid64927 Aug 19, 2023
b49e0bf
Fix: build error resolved
khalid64927 Aug 20, 2023
d439a9d
Fixed Fakerepos
khalid64927 Aug 20, 2023
f0cbf60
Fix: removed unused code
khalid64927 Aug 20, 2023
4cd64af
WIP: renamed module from app to mercari
khalid64927 May 1, 2024
e6dc840
Fixed compiler error and dep upgrade
khalid64927 May 3, 2024
abb74cb
Feature: added githubApp
khalid64927 May 4, 2024
ff65479
Chore: added ocbc app module
khalid64927 May 5, 2024
60f2bed
Chore: added rakuten module
khalid64927 May 5, 2024
91882e2
Chore: moved files up
khalid64927 May 5, 2024
e43bf06
Chore: added screenshots
khalid64927 May 5, 2024
e3e63f7
Chore: commented tests in rakutenApp
khalid64927 May 5, 2024
88aa5f2
Chore: reverted pipeline
khalid64927 May 5, 2024
d641cdd
Chore: fixed test cases
khalid64927 May 5, 2024
af1f79a
WIP dont push this
khalid64927 May 18, 2024
e19404c
WIP dont push this 2
khalid64927 May 18, 2024
8d8d3ff
refactored mercari package
khalid64927 May 19, 2024
fdf30e8
Fix: app run issue fixed
khalid64927 Jun 2, 2024
88b2297
Fix: test case fix
khalid64927 Jun 7, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
Binary file removed .DS_Store
Binary file not shown.
4 changes: 4 additions & 0 deletions .bundle/config
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
---
BUNDLE_RETRY: "3"
BUNDLE_JOBS: "4"
BUNDLE_PATH: "vendor/bundle"
46 changes: 46 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Bug Report
description: File a bug report
title: "[Bug]: "
labels: ["bug", "triage me"]
body:
- type: markdown
attributes:
value: |
Thanks for taking the time to fill out this bug report!
- type: checkboxes
attributes:
label: Is there an existing issue for this?
description: Please search to see if an issue already exists for the bug you encountered.
options:
- label: I have searched the existing issues
required: true
- type: checkboxes
attributes:
label: Is there a StackOverflow question about this issue?
description: Please search [StackOverflow](https://stackoverflow.com/questions/tagged/android-jetpack) if an issue with an answer already exists for the bug you encountered.
options:
- label: I have searched StackOverflow
required: true
- type: textarea
id: what-happened
attributes:
label: What happened?
description: Also tell us, what did you expect to happen?
placeholder: Tell us what you see!
value: "A bug happened!"
validations:
required: true
- type: textarea
id: logs
attributes:
label: Relevant logcat output
description: Please copy and paste any relevant logcat output. This will be automatically formatted into code, so no need for backticks.
render: shell
- type: checkboxes
id: terms
attributes:
label: Code of Conduct
description: By submitting this issue, you agree to follow our [Code of Conduct](CODE_OF_CONDUCT.md)
options:
- label: I agree to follow this project's Code of Conduct
required: true
46 changes: 46 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Feature request
description: File a feature request
title: "[FR]: "
labels: ["enhancement", "triage me"]
body:
- type: markdown
attributes:
value: |
Thanks for taking the time to fill out this bug report!
- type: checkboxes
attributes:
label: Is there an existing issue for this?
description: Please search to see if an issue already exists for this feature request.
options:
- label: I have searched the existing issues
required: true
- type: textarea
id: describe-problem
attributes:
label: Describe the problem
description: Is your feature request related to a problem? Please describe.
placeholder: I'm always frustrated when...
validations:
required: true
- type: textarea
id: solution
attributes:
label: Describe the solution
description: Please describe the solution you'd like. A clear and concise description of what you want to happen.
validations:
required: true
- type: textarea
id: context
attributes:
label: Additional context
description: Add any other context or screenshots about the feature request here.
validations:
required: false
- type: checkboxes
id: terms
attributes:
label: Code of Conduct
description: By submitting this issue, you agree to follow our [Code of Conduct](CODE_OF_CONDUCT.md)
options:
- label: I agree to follow this project's Code of Conduct
required: true
16 changes: 16 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
name: Pull request
about: Create a pull request
label: 'triage me'
---
Thank you for opening a Pull Request!
Before submitting your PR, there are a few things you can do to make sure it goes smoothly:
- [ ] Make sure to open a GitHub issue as a bug/feature request before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea
- [ ] Ensure the tests and linter pass (`./gradlew spotlessApply` to automatically apply formatting)
- [ ] Appropriate docs were updated (if necessary)

Is this your first Pull Request?
- [ ] Run `./tools/setup.sh`
- [ ] Import the code formatting style as explained in [the setup script](/tools/setup.sh#L40).

Fixes #<issue_number_goes_here> 🦕
44 changes: 44 additions & 0 deletions .github/scripts/dependency-update-report-mail-sender.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
module.exports = ({ }) => {
const execSync = require('child_process').execSync
execSync(`npm install nodemailer`) // Install nodemailer
const nodemailer = require('nodemailer')
const transporter = nodemailer.createTransport({
host: "smtp.live.com", // Host for hotmail
port: 587,
secureConnection: false,
auth: {
user: `${process.env.MAIL_USERNAME}`,
pass: `${process.env.MAIL_PASSWORD}`
},
tls: {
ciphers: 'SSLv3'
}
});
path = require('path')
console.log("Current directory:", __dirname);
let reqPath = path.join(__dirname, '../../mercari/build/dependencyUpdates/report.html')
console.log("reqPath :", reqPath);
const report = require('fs').readFileSync(reqPath)

const mailOptions = {
from: {
name: 'GitHubRepos',
address: process.env.MAIL_USERNAME
},
to: '[email protected]', // Use your main account to get the email
subject: 'Dependency update report of AndroidCore ¯\\_(ツ)_/¯',
text: `${report}`,
attachments : [
{ // utf-8 string as an attachment
filename: 'build.gradle.kts',
path: reqPath
}
]
};

transporter.sendMail(mailOptions, (error, info) => {
if (error) {
console.log(error)
}
});
}
54 changes: 43 additions & 11 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,32 +1,64 @@
name: Android CI Build

on: pull_request
on:
pull_request:
workflow_dispatch:
concurrency:
group: build-${{ github.ref }}
cancel-in-progress: true

jobs:
build:
runs-on: ubuntu-latest
timeout-minutes: 60

steps:
- uses: actions/checkout@v1
- name: Checkout
uses: actions/checkout@v3

- name: Validate Gradle Wrapper
uses: gradle/wrapper-validation-action@v1

- name: Set up JDK
uses: actions/setup-java@v1
with:
java-version: 11
java-version: 17

- name: Setup Gradle
uses: gradle/gradle-build-action@v2

- name: Run Spotless
run: cd GitHubRepos && ./gradlew app:spotlessCheck
run: ./gradlew mercari:spotlessCheck --stacktrace

- name: Run Lint
run: cd GitHubRepos && ./gradlew app:lintProdDebug --stacktrace
run: ./gradlew mercari:lintProdDebug --stacktrace

- name: Run Jacoco
run: ./gradlew jacocoTestReport --stacktrace

- name: Setup Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: '3.2.0-preview1'
bundler-cache: true

- name: Run Tests
run: cd GitHubRepos && ./gradlew app:testProdDebugUnitTest
- name: Run Danger
if: github.event_name == 'pull_request'
run: |
# install danger and its dependencies using bundler
cd GitHubRepos && gem install bundler
# install all bundles from Gemfile
bundle install --jobs 4 --retry 3
# execute danger for this PR
bundle exec danger --dangerfile=Dangerfile --danger_id=danger-pr
env:
# the token used by danger to report the results on the PR
DANGER_GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Build
run: cd GitHubRepos && ./gradlew app:assembleProdDebug
run: ./gradlew mercari:assembleProdDebug --stacktrace

# TODO: fix OSS errors
#- name: OSS Scan
# run: cd GitHubRepos && ./gradlew dependencyCheckAnalyze --info
- name: OSS Scan
run: ./gradlew mercari:dependencyCheckAnalyze --info


27 changes: 27 additions & 0 deletions .github/workflows/dependency-update.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Check Dependency Updates
on:
schedule:
- cron: "37 13 * * SAT"
workflow_dispatch:
jobs:
dependency-updates:
runs-on: ubuntu-latest
steps:
# Removed some steps for brevity
- name: Checkout code
uses: actions/checkout@v2

- name: Log dependency update report
run: cat mercari/build/dependencyUpdates/report.html

- name: 💌 Send email report
if: ${{ github.event_name == 'schedule' || github.event_name == 'workflow_dispatch' }}
uses: actions/github-script@v3
env:
MAIL_USERNAME: ${{ secrets.MAIL_USERNAME }}
MAIL_PASSWORD: ${{ secrets.MAIL_PASSWORD }}
with:
script: |
const scriptPath = '.github/scripts/dependency-update-report-mail-sender.js'
const script = require(`${process.env.GITHUB_WORKSPACE}${scriptPath}`)
script({ })
2 changes: 2 additions & 0 deletions GitHubRepos/.gitignore → .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,7 @@
.externalNativeBuild
.cxx
.DG_Store
/.DS_Store
/buildSrc/build/
/.idea/shelf/
.DS_Store
9 changes: 0 additions & 9 deletions .idea/AndroidCore.iml

This file was deleted.

File renamed without changes.
2 changes: 1 addition & 1 deletion GitHubRepos/.idea/compiler.xml → .idea/compiler.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 10 additions & 0 deletions .idea/deploymentTargetDropDown.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

30 changes: 30 additions & 0 deletions .idea/deploymentTargetSelector.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

File renamed without changes.
35 changes: 35 additions & 0 deletions .idea/gradle.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

File renamed without changes.
6 changes: 6 additions & 0 deletions .idea/kotlinc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions .idea/markdown-navigator/profiles_settings.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading