Skip to content

Commit

Permalink
chore: Remove photos scripts from package.json
Browse files Browse the repository at this point in the history
  • Loading branch information
JF-Cozy committed Dec 12, 2023
1 parent a8fbe7f commit 9fc6a36
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 24 deletions.
8 changes: 3 additions & 5 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,6 @@ jobs:
name: "Drive web"
stage: "build"
<<: *node
env:
- COZY_APP_SLUG=drive
before_script:
- yarn run cozy-ci-transifex
- scripts/decrypt.sh
Expand All @@ -51,10 +49,10 @@ jobs:
- yarn tx
- echo -en 'travis_fold:end:txpull\\r'
- echo 'build' && echo -en 'travis_fold:start:build\\r'
- yarn build:$COZY_APP_SLUG:browser
- yarn build
- echo -en 'travis_fold:end:build\\r'
- &downcloud-cert if [ "$TRAVIS_SECURE_ENV_VARS" != "false" ]; then eval "$(ssh-agent -s)" && chmod 600 /tmp/id_rsa_travis_downcloud && ssh-add /tmp/id_rsa_travis_downcloud; fi # Needs to be inlined and not in a script to work.
- if [ "${COZY_APP_SLUG}" == "drive" ]; then yarn bundlemon; fi
- yarn bundlemon
#- echo 'create and deploy' && echo -en 'travis_fold:start:createanddeploy\\r'
#- if [ "$TRAVIS_PULL_REQUEST" != "false" ]; then ./scripts/create-deploy-test.sh; fi
#- echo -en 'travis_fold:end:createanddeploy\\r'
Expand All @@ -68,7 +66,7 @@ jobs:
provider: script
repo: cozy/cozy-drive
skip-cleanup: true
script: yarn run deploy:$COZY_APP_SLUG
script: yarn run deploy
on:
branch: master
- <<: *deploy
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,14 +54,14 @@ Cozy's apps use a standard set of _npm scripts_ to run common tasks, like watch,
Using a watcher - with Hot Module Replacement:
```sh
$ cd cozy-drive
$ yarn watch:drive:browser
$ yarn watch
$ cozy-stack serve --appdir drive:/<project_absolute_path>/cozy-drive/build/drive --disable-csp
```

Or directly build the app (static file generated):
```sh
$ cd cozy-drive
$ yarn build:drive
$ yarn build
$ cozy-stack serve --appdir drive:/<project_absolute_path>/cozy-drive/build/drive
```

Expand All @@ -76,7 +76,7 @@ You can easily view your current running app, you can use the [cozy-stack docker
```sh
# in a terminal, run your app in watch mode
$ cd cozy-drive
$ yarn watch:drive:browser
$ yarn watch
```

```sh
Expand Down
21 changes: 5 additions & 16 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,29 +3,19 @@
"version": "1.65.0",
"main": "src/main.jsx",
"scripts": {
"build": "yarn build:drive && yarn build:photos",
"build:drive": "yarn build:drive:browser",
"build:drive:browser": "COZY_APP_SLUG=drive cozy-scripts build --manifest src/drive/targets/manifest.webapp --build-dir build/drive --src-dir src/drive --barV7 false --cozyClientJs",
"build": "COZY_APP_SLUG=drive cozy-scripts build --manifest src/drive/targets/manifest.webapp --build-dir build/drive --src-dir src/drive --barV7 false --cozyClientJs",
"build:drive:mobile": "COZY_APP_SLUG=drive cozy-scripts build --mobile --manifest src/drive/targets/manifest.webapp --src-dir src/drive --barV7 false --cozyClientJs",
"watch:drive": "yarn watch:drive:browser",
"watch:drive:browser": "COZY_APP_SLUG=drive cozy-scripts watch --manifest src/drive/targets/manifest.webapp --build-dir build/drive --src-dir src/drive --barV7 false --cozyClientJs",
"watch": "COZY_APP_SLUG=drive cozy-scripts watch --manifest src/drive/targets/manifest.webapp --build-dir build/drive --src-dir src/drive --barV7 false --cozyClientJs",
"watch:drive:mobile": "COZY_APP_SLUG=drive NODE_ENV=mobile:development cozy-scripts watch --manifest src/drive/targets/manifest.webapp --src-dir src/drive --barV7 false --cozyClientJs",
"start:drive:browser": "COZY_APP_SLUG=drive cozy-scripts start --manifest src/drive/targets/manifest.webapp --build-dir build/drive --src-dir src/drive --barV7 false --cozyClientJs",
"start": "COZY_APP_SLUG=drive cozy-scripts start --manifest src/drive/targets/manifest.webapp --build-dir build/drive --src-dir src/drive --barV7 false --cozyClientJs",
"start:drive:mobile": "COZY_APP_SLUG=drive NODE_ENV=mobile:development cozy-scripts start --mobile --manifest src/drive/targets/manifest.webapp --src-dir src/drive --barV7 false --cozyClientJs",
"start:drive:standalone": "COZY_APP_SLUG=drive NODE_ENV=mobile:development cozy-scripts start --manifest src/drive/targets/manifest.webapp --src-dir src/drive --barV7 false --cozyClientJs",
"build:photos": "yarn build:photos:browser",
"build:photos:browser": "COZY_APP_SLUG=photos cozy-scripts build --manifest src/photos/targets/manifest.webapp --build-dir build/photos --src-dir src/photos --barV7 false --cozyClientJs",
"watch:photos": "yarn watch:photos:browser",
"watch:photos:browser": "COZY_APP_SLUG=photos cozy-scripts watch --manifest src/photos/targets/manifest.webapp --build-dir build/photos --src-dir src/photos --barV7 false --cozyClientJs",
"start:photos:browser": "COZY_APP_SLUG=photos cozy-scripts start --manifest src/photos/targets/manifest.webapp --build-dir build/photos --src-dir src/photos --barV7 false --cozyClientJs",
"deploy:drive": "cozy-app-publish --token $REGISTRY_TOKEN --build-dir 'build/drive/' --prepublish downcloud --postpublish mattermost",
"deploy:photos": "cozy-app-publish --token $REGISTRY_TOKEN --build-dir 'build/photos/' --prepublish downcloud --postpublish mattermost",
"deploy": "cozy-app-publish --token $REGISTRY_TOKEN --build-dir 'build/drive/' --prepublish downcloud --postpublish mattermost",
"tx": "tx pull --all || true",
"lint": "npm-run-all --parallel 'lint:*'",
"lint:styles": "stylint src --config ./node_modules/cozy-scripts/config/.stylintrc",
"lint:js": "eslint '{src,test}/**/*.{js,jsx}'",
"testcafe:drive": "node testcafe/runner-drive.js",
"testcafe:photos": "node testcafe/runner-photos.js",
"test": "env NODE_ENV='test' jest",
"genicon:drive:mobile": "(cd src/drive/targets/mobile && rm -Rf ./res/icons ./res/screens && splashicon-generator --imagespath='./res/model' && cp res/model/splash.png res/screens/ios/Default@2x~universal~anyany.png)",
"prepare:drive:mobile": "(cd src/drive/targets/mobile && rm -rf platforms && rm -rf plugins && cordova prepare)",
Expand All @@ -50,8 +40,7 @@
"version:drive:androidbuild": "perl -pi -e 's,android-versionCode=\"[0-9]+\",android-versionCode=\"'`echo ${npm_package_version} | tr -d .`'0000\",g' ./src/drive/targets/mobile/config.xml",
"version:drive:useragent": "replace 'value=\"(.+)\\d+\\.\\d+\\.\\d+\"' 'value=\"$1'$npm_package_version'\"' ./src/drive/targets/mobile/config.xml",
"version:drive": "npm-run-all --parallel 'version:drive:*'",
"service:drive": "yarn cozy-konnector-dev -m src/photos/targets/manifest.webapp",
"service:photos": "yarn cozy-konnector-dev -m src/photos/targets/manifest.webapp"
"service:drive": "yarn cozy-konnector-dev -m src/photos/targets/manifest.webapp"
},
"repository": {
"type": "git",
Expand Down

0 comments on commit 9fc6a36

Please sign in to comment.