Updates workflows

This commit is contained in:
Mouse Reeve 2022-02-15 12:25:35 -08:00
parent b601ac6f91
commit 714bb081ea
9 changed files with 10 additions and 1551 deletions

View file

@ -22,7 +22,7 @@ jobs:
- uses: actions/checkout@v2
- name: Install modules
run: yarn
run: yarn dev-tools
# See .stylelintignore for files that are not linted.
- name: Run stylelint

View file

@ -17,8 +17,7 @@ jobs:
- uses: actions/checkout@v2
- name: Install modules
run: npm install .
run: npm install dev-tools
# See .stylelintignore for files that are not linted.
- name: Run Prettier
run: npx prettier --check bookwyrm/static/js/*.js

2
.gitignore vendored
View file

@ -24,7 +24,7 @@
.idea
#Node tools
/node_modules/
node_modules/
#nginx
nginx/default.conf

8
bw-dev
View file

@ -97,7 +97,7 @@ case "$CMD" in
docker-compose restart celery_worker
;;
pytest)
execweb pytest --no-cov-on-fail "$@"
runweb pytest --no-cov-on-fail "$@"
;;
collectstatic)
runweb python manage.py collectstatic --no-input
@ -141,9 +141,9 @@ case "$CMD" in
docker-compose run --rm dev-tools npx stylelint bookwyrm/static/**/*.css --fix
;;
formatters)
makeitblack
docker-compose run --rm dev-tools npx prettier --write bookwyrm/static/js/*.js
docker-compose run --rm dev-tools npx stylelint bookwyrm/static/**/*.css --fix
docker-compose run --rm dev-tools black celerywyrm bookwyrm && \
npx prettier --write bookwyrm/static/js/*.js && \
npx stylelint bookwyrm/static/**/*.css --fix
;;
update)
git pull

View file

@ -6,7 +6,7 @@ RUN mkdir /app /app/static /app/images
WORKDIR /app
COPY package.json requirements.txt /app/
COPY package.json requirements.txt .stylelintrc.js .stylelintignore /app/
RUN pip install black
RUN apt-get update && apt-get install -y curl

View file

@ -5,9 +5,7 @@
"devDependencies": {
"eslint": "^8.9.0",
"prettier": "2.5.1",
"stylelint": "^14.2.0",
"stylelint-config-standard": "^25.0.0",
"stylelint-order": "^5.0.0",
"stylelint": "^14.5.0",
"watch": "^0.13.0"
},
"dependencies": {

View file

@ -85,7 +85,7 @@ services:
- redis_broker
restart: on-failure
dev-tools:
build: dev-tools-docker
build: dev-tools
env_file: .env
volumes:
- .:/app

1538
yarn.lock

File diff suppressed because it is too large Load diff