1
0
mirror of https://github.com/kremalicious/portfolio.git synced 2024-12-22 09:13:19 +01:00

script tweaks

This commit is contained in:
Matthias Kretschmann 2018-06-20 23:38:08 +02:00
parent 88bbd1fb2f
commit e0fa761c3b
Signed by: m
GPG Key ID: 606EEEF3C479A91F
4 changed files with 7 additions and 3 deletions

View File

@ -9,14 +9,14 @@
"scripts": {
"lint:js": "eslint ./gatsby-*.{js,jsx} && eslint ./src/**/*.{js,jsx}",
"lint:css": "stylelint ./src/**/*.{css,scss}",
"lint": "npm run lint:js && npm run lint:css",
"lint": "npm run svg && npm run lint:js && npm run lint:css",
"build": "npm run svg && ./node_modules/gatsby/dist/bin/gatsby.js build",
"start": "npm run svg && ./node_modules/gatsby/dist/bin/gatsby.js develop",
"format": "prettier --write 'src/**/*.{js,jsx}'",
"format:css": "prettier-stylelint --write --quiet 'src/**/*.{css,scss}'",
"test": "npm run lint",
"deploy": "./scripts/deploy.sh",
"new": "node ./scripts/new-project.js",
"new": "node ./scripts/new.js",
"svg": "./scripts/svg.sh"
},
"dependencies": {

View File

@ -4,7 +4,7 @@ const prepend = require('prepend')
const slugify = require('slugify')
const ora = require('ora')
const templatePath = path.join(__dirname, 'new-project.yml')
const templatePath = path.join(__dirname, 'new.yml')
const template = fs.readFileSync(templatePath).toString()
const spinner = ora('Adding new project').start()

View File

@ -4,5 +4,9 @@ set -e
SRC='./src/images'
OUT='./src/components/svg'
printf "Creating SVG components...\\n\\n"
# Usage: svgr [-d out-dir] [src-dir]
./node_modules/@svgr/cli/bin/svgr --icon -d $OUT $SRC
printf "\\n🎉 Successfully created SVG components\\n\\n"