Merge pull request #2008 from crazyserver/andrewnicols-MOBILE-2925
MOBILE-2925 install: Switch to using npx for package build
This commit is contained in:
		
						commit
						b32bec9b59
					
				| @ -15,8 +15,7 @@ cache: | ||||
|     - $HOME/.cache/electron-builder | ||||
| 
 | ||||
| before_script: | ||||
|   - npm install -g @angular/cli | ||||
|   - npm i npm@latest -g | ||||
|   - npm install npm@latest -g | ||||
|   - gulp | ||||
| 
 | ||||
| script: | ||||
|  | ||||
							
								
								
									
										12
									
								
								Dockerfile
									
									
									
									
									
								
							
							
						
						
									
										12
									
								
								Dockerfile
									
									
									
									
									
								
							| @ -11,17 +11,17 @@ EXPOSE 35729 | ||||
| # Port 53703 is the Chrome dev logger port. | ||||
| EXPOSE 53703 | ||||
| 
 | ||||
| # MoodleMobile uses Ionic and Gulp. | ||||
| RUN npm i -g ionic gulp && rm -rf /root/.npm | ||||
| 
 | ||||
| WORKDIR /app | ||||
| 
 | ||||
| COPY . /app | ||||
| 
 | ||||
| # Install npm libraries and run gulp to initialize the project. | ||||
| RUN npm install && gulp && rm -rf /root/.npm | ||||
| # Install npm libraries. | ||||
| RUN npm install && rm -rf /root/.npm | ||||
| 
 | ||||
| # Run gulp before starting. | ||||
| RUN npx gulp | ||||
| 
 | ||||
| # Provide a Healthcheck command for easier use in CI. | ||||
| HEALTHCHECK --interval=10s --timeout=3s --start-period=30s CMD curl -f http://localhost:8100 || exit 1 | ||||
| 
 | ||||
| CMD ["ionic", "serve", "-b"] | ||||
| CMD ["npm", "run", "ionic:serve"] | ||||
|  | ||||
							
								
								
									
										4889
									
								
								package-lock.json
									
									
									
										generated
									
									
									
								
							
							
						
						
									
										4889
									
								
								package-lock.json
									
									
									
										generated
									
									
									
								
							
										
											
												File diff suppressed because it is too large
												Load Diff
											
										
									
								
							
							
								
								
									
										35
									
								
								package.json
									
									
									
									
									
								
							
							
						
						
									
										35
									
								
								package.json
									
									
									
									
									
								
							| @ -23,21 +23,21 @@ | ||||
|     } | ||||
|   ], | ||||
|   "scripts": { | ||||
|     "setup": "npm install && cordova prepare && gulp", | ||||
|     "clean": "ionic-app-scripts clean", | ||||
|     "build": "ionic-app-scripts build", | ||||
|     "lint": "ionic-app-scripts lint", | ||||
|     "ionic:build": "node --max-old-space-size=16384 ./node_modules/@ionic/app-scripts/bin/ionic-app-scripts.js build", | ||||
|     "ionic:serve:before": "gulp", | ||||
|     "ionic:serve": "gulp watch | ionic-app-scripts serve", | ||||
|     "ionic:build:before": "gulp", | ||||
|     "ionic:watch:before": "gulp", | ||||
|     "ionic:build:after": "gulp copy-component-templates", | ||||
|     "preionic:build": "gulp", | ||||
|     "postionic:build": "gulp copy-component-templates", | ||||
|     "desktop.pack": "electron-builder --dir", | ||||
|     "desktop.dist": "electron-builder -p never", | ||||
|     "windows.store": "electron-windows-store --input-directory .\\desktop\\dist\\win-unpacked --output-directory .\\desktop\\store -a .\\resources\\desktop -m .\\desktop\\assets\\windows\\AppXManifest.xml --package-version 0.0.0.0 --package-name MoodleDesktop" | ||||
|     "setup": "npm install && npx cordova prepare && npx gulp", | ||||
|     "clean": "npx ionic-app-scripts clean", | ||||
|     "build": "npx ionic-app-scripts build", | ||||
|     "lint": "npx ionic-app-scripts lint", | ||||
|     "ionic:build": "npx --max-old-space-size=16384 ionic-app-scripts build", | ||||
|     "ionic:serve:before": "npx gulp", | ||||
|     "ionic:serve": "npx gulp watch & npx ionic-app-scripts serve -b --devapp --address=0.0.0.0", | ||||
|     "ionic:build:before": "npx gulp", | ||||
|     "ionic:watch:before": "npx gulp", | ||||
|     "ionic:build:after": "npx gulp copy-component-templates", | ||||
|     "preionic:build": "npx gulp", | ||||
|     "postionic:build": "npx gulp copy-component-templates", | ||||
|     "desktop.pack": "npx electron-builder --dir", | ||||
|     "desktop.dist": "npx electron-builder -p never", | ||||
|     "windows.store": "npx electron-windows-store --input-directory .\\desktop\\dist\\win-unpacked --output-directory .\\desktop\\store -a .\\resources\\desktop -m .\\desktop\\assets\\windows\\AppXManifest.xml --package-version 0.0.0.0 --package-name MoodleDesktop" | ||||
|   }, | ||||
|   "dependencies": { | ||||
|     "@angular/animations": "^5.2.10", | ||||
| @ -80,6 +80,7 @@ | ||||
|     "@types/promise.prototype.finally": "^2.0.2", | ||||
|     "chart.js": "^2.7.2", | ||||
|     "com-darryncampbell-cordova-plugin-intent": "^1.1.7", | ||||
|     "cordova": "8.1.2", | ||||
|     "cordova-android": "7.1.2", | ||||
|     "cordova-android-support-gradle-release": "^3.0.0", | ||||
|     "cordova-clipboard": "^1.2.1", | ||||
| @ -121,10 +122,10 @@ | ||||
|     "zone.js": "^0.8.26" | ||||
|   }, | ||||
|   "devDependencies": { | ||||
|     "@ionic/app-scripts": "^3.2.2", | ||||
|     "@ionic/app-scripts": "3.2.2", | ||||
|     "electron-builder-lib": "^20.23.1", | ||||
|     "electron-rebuild": "^1.8.1", | ||||
|     "gulp": "^4.0.2", | ||||
|     "gulp": "4.0.2", | ||||
|     "gulp-clip-empty-files": "^0.1.2", | ||||
|     "gulp-concat": "^2.6.1", | ||||
|     "gulp-flatten": "^0.4.0", | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user