Rewrite version of all metadata.json in Cinnamon Extension
When upgrating version of Cinnamon, extensions is not working often.
This tip makes such Cinnamon Extensions work well.
Create a shellscript
Create a shellscript file named rewriteVer.sh as following code
#!/bin/sh
var=`cinnamon --version | sed s/"Cinnamon "//g`
echo cinnamon --version: $var
echo rewriting version of Cinnamon Extension
perl -p -i.bk -e "s|\"cinnamon-version\": \[.*\]|\"cinnamon-version\": \[\"$var\"\]|gc" $HOME/.local/share/cinnamon/extensions/*/metadata.json
Edit Permission
$ sudo chmod 775 rewriteVer.sh
Run Script
$ rewriteVer.sh
Restart Cinnamon
press Alt + F2
and type r
Written by Kohei Yamada
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Shell
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#