Compare commits
3 Commits
ab7380c93b
...
4f284269f4
Author | SHA1 | Date |
---|---|---|
Michel | 4f284269f4 | |
Michel | 937a0a0969 | |
Michel | 7368cf81b7 |
|
@ -0,0 +1,71 @@
|
|||
# GIT ArkenFox
|
||||
|
||||
## MàJ repository
|
||||
|
||||
```
|
||||
$ git fetch
|
||||
$ git checkout 95.0
|
||||
```
|
||||
|
||||
**Vérifications des modifications locales**
|
||||
|
||||
$ git diff
|
||||
|
||||
**Lien symbolique depuis le répertoire Mozilla**
|
||||
|
||||
```
|
||||
$ cd ~/.mozilla/firefox/
|
||||
$ ln -sf ~/dev_3rd/FF_arkenfox_user.js/user.js .
|
||||
```
|
||||
|
||||
## Nettoyage
|
||||
|
||||
Important de nettoyer car certaines lignes peuvent avoir été retirées.
|
||||
|
||||
```
|
||||
$ cd ~/.mozilla/firefox/abcdef12.profile
|
||||
$ ~/dev_3rd/FF_arkenfox_user.js/prefsCleaner.sh
|
||||
$ cd ..
|
||||
```
|
||||
|
||||
|
||||
## Création
|
||||
|
||||
```
|
||||
$ ~/dev_3rd/FF_arkenfox_user.js/updater.sh -lc
|
||||
```
|
||||
|
||||
|
||||
# Search
|
||||
|
||||
```
|
||||
$ SUFFIX=$(kdialog --inputbox "Suffix" $(date +%Y-%m-%d)) \
|
||||
&& TMP=$(mktemp) \
|
||||
&& mozlz4a.py --decompress search.json.mozlz4 $TMP \
|
||||
&& jq . --indent 2 $TMP > search_${SUFFIX}.json \
|
||||
&& rm $TMP
|
||||
```
|
||||
|
||||
|
||||
# Archive
|
||||
|
||||
## Télécharger Arkenfox
|
||||
|
||||
Méthode alternative — au lieu d'utiliser GIT.
|
||||
|
||||
```
|
||||
$ cd ~/.mozilla/firefox/
|
||||
|
||||
$ wget https://github.com/arkenfox/user.js/archive/refs/tags/86.0.tar.gz
|
||||
$ mv 86.0.tar.gz user.js-86.0.tar.gz
|
||||
$ tar xf user.js-86.0.tar.gz
|
||||
|
||||
$ DIR=$(echo user.js*(/om[1])) && ln -sf $DIR/user.js .
|
||||
```
|
||||
|
||||
**Vérifications**
|
||||
|
||||
```
|
||||
$ DIR=$(echo user.js*(/om[1])) && kdiff3 ~/dev_3rd/FF_arkenfox_user.js/updater.sh $DIR/updater.sh updater_local.sh
|
||||
```
|
||||
|
|
@ -9,13 +9,13 @@
|
|||
currdir=$(pwd)
|
||||
|
||||
## get the full path of this script (readlink for Linux, greadlink for Mac with coreutils installed)
|
||||
sfp=$(readlink -f "${BASH_SOURCE[0]}" 2>/dev/null || greadlink -f "${BASH_SOURCE[0]}" 2>/dev/null)
|
||||
#sfp=$(readlink -f "${BASH_SOURCE[0]}" 2>/dev/null || greadlink -f "${BASH_SOURCE[0]}" 2>/dev/null)
|
||||
|
||||
## fallback for Macs without coreutils
|
||||
if [ -z "$sfp" ]; then sfp=${BASH_SOURCE[0]}; fi
|
||||
#if [ -z "$sfp" ]; then sfp=${BASH_SOURCE[0]}; fi
|
||||
|
||||
## change directory to the Firefox profile directory
|
||||
cd "$(dirname "${sfp}")"
|
||||
#cd "$(dirname "${sfp}")"
|
||||
|
||||
fQuit() {
|
||||
## change directory back to the original working directory
|
||||
|
|
|
@ -241,7 +241,7 @@ remove_comments() { # expects 2 arguments: from-file and to-file
|
|||
|
||||
# Applies latest version of user.js and any custom overrides
|
||||
update_userjs() {
|
||||
declare -r newfile="$(download_file 'https://raw.githubusercontent.com/arkenfox/user.js/master/user.js')"
|
||||
declare -r newfile="$HOME/.mozilla/firefox/user.js"
|
||||
[ -z "${newfile}" ] && echo -e "${RED}Error! Could not download user.js${NC}" && return 1 # check if download failed
|
||||
|
||||
echo -e "Please observe the following information:
|
||||
|
@ -255,7 +255,7 @@ update_userjs() {
|
|||
echo -e "\n"
|
||||
if [[ $REPLY =~ ^[Nn]$ ]]; then
|
||||
echo -e "${RED}Process aborted${NC}"
|
||||
rm "$newfile"
|
||||
#rm $newfile
|
||||
return 1
|
||||
fi
|
||||
fi
|
||||
|
@ -272,7 +272,7 @@ update_userjs() {
|
|||
[ "$BACKUP" = 'single' ] && bakname='userjs_backups/user.js.backup'
|
||||
cp user.js "$bakname" &>/dev/null
|
||||
|
||||
mv "${newfile}" user.js
|
||||
cp "${newfile}" user.js
|
||||
echo -e "Status: ${GREEN}user.js has been backed up and replaced with the latest version!${NC}"
|
||||
|
||||
if [ "$ESR" = true ]; then
|
||||
|
|
Loading…
Reference in New Issue