clean assets script

pull/12979/head
Carlos Matallín 7 years ago
parent fbf3bce8cd
commit 3e05acf618

@ -2,6 +2,7 @@ Development
----------- -----------
### Features ### Features
* Clean assets script
* Improve error on widgets (CartoDB/deep-insights.js#574) * Improve error on widgets (CartoDB/deep-insights.js#574)
* Add pagination support in data imports listing in superadmin (#12938). * Add pagination support in data imports listing in superadmin (#12938).
* Profile static view (#12704) * Profile static view (#12704)
@ -258,6 +259,13 @@ cd $(git rev-parse --show-toplevel)/lib/sql
sudo make install sudo make install
``` ```
To launch the clean assets script run the following in the terminal:
```shell
./script/clean_assets
```
It will remove old assets from `public/assets/` (older than version in `package.json`)
#### Dropbox API v2 migration #### Dropbox API v2 migration
Dropbox API v2 (#8303, #12300): [Dropbox deprecated API v1](https://blogs.dropbox.com/developers/2016/06/api-v1-deprecated/) Dropbox API v2 (#8303, #12300): [Dropbox deprecated API v1](https://blogs.dropbox.com/developers/2016/06/api-v1-deprecated/)

@ -0,0 +1,5 @@
#!/bin/sh
echo "--- Cleaning assets"
PACKAGE_VERSION=$(grep -m1 version package.json | awk -F: '{ print $2 }' | sed 's/[", ]//g')
find public/assets/* -type d ! -name $PACKAGE_VERSION -depth 0 | xargs rm -rf
Loading…
Cancel
Save