Commit 4c57bf77 authored by kosheo's avatar kosheo

Update CI script

parent d0373d13
Pipeline #23589860 passed with stages
in 5 minutes and 25 seconds
node_modules/ node_modules/
public/ dist/
coverage/ coverage/
package-lock.json package-lock.json
...@@ -16,7 +16,7 @@ build: ...@@ -16,7 +16,7 @@ build:
- npm run dist - npm run dist
artifacts: artifacts:
paths: paths:
- public - dist
lint: lint:
stage: test stage: test
...@@ -41,6 +41,10 @@ test: ...@@ -41,6 +41,10 @@ test:
pages: pages:
stage: deploy stage: deploy
script: script:
- ls public - mkdir public
- cp -r dist/* public
artifacts:
paths:
- public
only: only:
- master - master
...@@ -41,13 +41,13 @@ To build the production version of the Cl Calc website: ...@@ -41,13 +41,13 @@ To build the production version of the Cl Calc website:
``` ```
npm run dist npm run dist
``` ```
This will create `public` directory with generated HTML, CSS, JavaScript files and images. This will create `dist` directory with generated HTML, CSS, JavaScript files and images.
For development build do: For development build do:
``` ```
npm run dev npm run dev
``` ```
In development build `public` directory will also contain source maps for JavaScript files and HTML files won't be minified. In addition to that, a web server will be started hosting `public` contents at http://localhost:8080. It watches for changes and automatically re-runs necessary tasks to regenerate HTML, CSS or JavaScript as needed. In development build `dist` directory will also contain source maps for JavaScript files and HTML files won't be minified. In addition to that, a web server will be started hosting `dist` contents at http://localhost:8080. It watches for changes and automatically re-runs necessary tasks to regenerate HTML, CSS or JavaScript as needed.
# Test # Test
......
...@@ -10,7 +10,7 @@ var gulp = require('gulp'), ...@@ -10,7 +10,7 @@ var gulp = require('gulp'),
sourcemaps = require('gulp-sourcemaps'), sourcemaps = require('gulp-sourcemaps'),
eslint = require('gulp-eslint'), eslint = require('gulp-eslint'),
dev = false, dev = false,
OUTPUT_DIR = './public'; OUTPUT_DIR = './dist';
/** /**
* Copy static assets to the output folder. * Copy static assets to the output folder.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment