FIRST Phone App Github Migration
Agenda
- Why & Goals
- How
- Demo
Why?
Everyone needs to be using Github Enterprise (GHE) by the end of the year instead of SVN, which will become read-only.
But...
the FIRST Phone apps shouldn't just be lift and shift
Hmmm...

Version of the Truth?
So now we have business components being duplicated for every single application and branch
(thanks to Michael Celeste for generating this report)

Other Issues
- Build process in Jenkins is tied to SVN
- Everything in one repo - web and cordova
- Setup process isn't very clear
- Build and deploy process is a bit of a black box
- Legacy version of cordova and Android Studio
Goals
- Must-Haves
- All code in Github
- Limit change as much as possible
- Reusable modules / components
- Framework is re-usable
- Business components are re-usable
- Setup, build, and deploy are simple, easy to understand, and well documented
- Nice-to-Haves
- Host in PCF
- CI/CD with Concourse
Code Walkthrough
Webapp
-
git clone https://github.homedepot.com/Back-Office-And-In-Aisle-Systems/asset-protection-ui - readme.md has instructions on how to proceed
-
grunt setup- Look at bower.json and Gruntfile.js
- Framework and Environment (Android) are in separate repos
- Business Components are in separate repos
Gruntfile.js
grunt.initConfig({
bower: {
install: {
options: {
targetDir: './bower_components',
verbose: true,
cleanTargetDir: false,
cleanBowerDir: false,
copy: false
}
}
},
bowercopy: {
options: {
clean: true
},
setup: {
options: {
},
files: {
// destination: source
'www/Framework': 'framework',
'www/Environment': 'environment',
'www/BusinessComponents/HazardousMaterials': 'components-hazmat',
'www/BusinessComponents/Checklist': 'components-checklist'
}
}
},
...bower.json
{
"name": "bower-test",
"authors": [
"Bryan Rosenbaum <bryan_rosenbaum@homedepot.com>"
],
"description": "",
"main": "",
"license": "MIT",
"homepage": "",
"private": true,
"ignore": [
"**/.*",
"node_modules",
"bower_components",
"app/components/",
"test",
"tests"
],
"dependencies": {
"environment": "git@github.homedepot.com:Back-Office-And-In-Aisle-Systems/first-phone-environment-android.git",
"framework": "git@github.homedepot.com:Back-Office-And-In-Aisle-Systems/first-phone-framework.git",
"components-hazmat": "git@github.homedepot.com:Back-Office-And-In-Aisle-Systems/first-phone-components-hazardous-materials",
"components-checklist": "git@github.homedepot.com:Back-Office-And-In-Aisle-Systems/first-phone-components-checklist"
}
}
Cordova Wrapper
-
git clone https://github.homedepot.com/Back-Office-And-In-Aisle-Systems/asset-protection-android - readme.md has instructions on how to proceed
-
cordova run android
Goals Review
- Must-Haves
- All code in Github
- Limit change as much as possible
- Reusable modules / components
- Framework is re-usable
- Business components are re-usable
- Setup, build, and deploy are simple, easy to understand, and well documented
- Nice-to-Haves
- Host in PCF
- CI/CD with Concourse
Next Steps
- App icon
- CI/CD with Concourse
- Signing the build
- Choose environment (e.g. web)
Appendix: Repo Links
https://github.homedepot.com/Back-Office-And-In-Aisle-Systems/asset-protection-android
https://github.homedepot.com/Back-Office-And-In-Aisle-Systems/asset-protection-ui
https://github.homedepot.com/Back-Office-And-In-Aisle-Systems/first-phone-framework
https://github.homedepot.com/Back-Office-And-In-Aisle-Systems/first-phone-environment-android
https://github.homedepot.com/Back-Office-And-In-Aisle-Systems/first-phone-components-checklist
FIRST Phone GHE Migration
By bryanrosenbaum
FIRST Phone GHE Migration
- 553