Merge branch 'move-js' into 'master'
Move Vue app to a "webapp" directory See merge request openflexure/openflexure-microscope-server!122
|
|
@ -21,12 +21,12 @@ stages:
|
||||||
# Re-usable block to install (and cache) openflexure-microscope-server static app
|
# Re-usable block to install (and cache) openflexure-microscope-server static app
|
||||||
.node-install-template: &node-install
|
.node-install-template: &node-install
|
||||||
before_script:
|
before_script:
|
||||||
- cd openflexure_microscope/api/static/
|
- cd webapp
|
||||||
- npm install
|
- npm install
|
||||||
cache:
|
cache:
|
||||||
key: "${CI_COMMIT_REF_SLUG}"
|
key: "${CI_COMMIT_REF_SLUG}"
|
||||||
paths:
|
paths:
|
||||||
- openflexure_microscope/api/static/node_modules
|
- webapp/node_modules
|
||||||
|
|
||||||
# Python static analysis with PyLint
|
# Python static analysis with PyLint
|
||||||
pylint:
|
pylint:
|
||||||
|
|
@ -162,7 +162,7 @@ build:
|
||||||
name: "dist"
|
name: "dist"
|
||||||
expire_in: 1 week
|
expire_in: 1 week
|
||||||
paths:
|
paths:
|
||||||
- "./openflexure_microscope/api/static/dist/"
|
- "openflexure_microscope/api/static/dist/"
|
||||||
|
|
||||||
only:
|
only:
|
||||||
- master
|
- master
|
||||||
|
|
|
||||||
|
|
@ -83,7 +83,7 @@ To set up a development version of the software (most likely using emulated came
|
||||||
* `curl -sL https://deb.nodesource.com/setup_14.x | sudo bash -`
|
* `curl -sL https://deb.nodesource.com/setup_14.x | sudo bash -`
|
||||||
* `sudo apt install nodejs`
|
* `sudo apt install nodejs`
|
||||||
* To build the web application (this produces a set of static files, that are served by the Flask webserver)
|
* To build the web application (this produces a set of static files, that are served by the Flask webserver)
|
||||||
* `cd openflexure_microscope/api/static`
|
* `cd webapp`
|
||||||
* `npm install`
|
* `npm install`
|
||||||
* `npm run build`
|
* `npm run build`
|
||||||
* To create a Node.js development server (this will help various development tools to display more information, and auto-rebuilds when you change the source files)
|
* To create a Node.js development server (this will help various development tools to display more information, and auto-rebuilds when you change the source files)
|
||||||
|
|
@ -97,14 +97,14 @@ All of the commands below assume that you are running in the OFM virtual environ
|
||||||
|
|
||||||
* To auto-format the Python code run `poe format`
|
* To auto-format the Python code run `poe format`
|
||||||
* To auto-format the Javascript code, run
|
* To auto-format the Javascript code, run
|
||||||
* `cd openflexure_microscope/api/static`
|
* `cd webapp`
|
||||||
* `npm run lint`
|
* `npm run lint`
|
||||||
|
|
||||||
**Before submitting a merge request/merging** please auto-format your code and also run the quality checks (linting, static analysis, and unit tests)
|
**Before submitting a merge request/merging** please auto-format your code and also run the quality checks (linting, static analysis, and unit tests)
|
||||||
|
|
||||||
* To auto-format and type-check the Python code run `poe check`
|
* To auto-format and type-check the Python code run `poe check`
|
||||||
* To auto-format the Javascript code, run
|
* To auto-format the Javascript code, run
|
||||||
* `cd openflexure_microscope/api/static`
|
* `cd webapp`
|
||||||
* `npm run lint`
|
* `npm run lint`
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.3 KiB |
|
Before Width: | Height: | Size: 1.6 KiB After Width: | Height: | Size: 1.6 KiB |
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 1.7 KiB |
3
webapp/vue.config.js
Normal file
|
|
@ -0,0 +1,3 @@
|
||||||
|
module.exports = {
|
||||||
|
outputDir: '../openflexure_microscope/api/static/dist',
|
||||||
|
};
|
||||||