Skip to content

Commit

Permalink
Fix ynh-3 compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
maniackcrudelis committed Jul 21, 2018
1 parent d3b2029 commit 8ac40c5
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 0 deletions.
10 changes: 10 additions & 0 deletions scripts/install
Expand Up @@ -118,6 +118,16 @@ then
done <<< "$(yunohost app list -i | grep id: | sed 's/.*id: //')"
fi

#=================================================
# STRETCH COMPATIBILITY
#=================================================

if is_stretch
then
ynh_replace_string "yunohost backup create --ignore-apps" "yunohost backup create" "$final_path/archivist.sh"
ynh_replace_string "yunohost backup create --ignore-system" "yunohost backup create" "$final_path/archivist.sh"
fi

#=================================================
# SET THE CRON FILE
#=================================================
Expand Down
10 changes: 10 additions & 0 deletions scripts/restore
Expand Up @@ -39,6 +39,16 @@ test ! -d $final_path \

ynh_restore_file "$final_path"

#=================================================
# STRETCH COMPATIBILITY
#=================================================

if is_stretch
then
ynh_replace_string "yunohost backup create --ignore-apps" "yunohost backup create" "$final_path/archivist.sh"
ynh_replace_string "yunohost backup create --ignore-system" "yunohost backup create" "$final_path/archivist.sh"
fi

#=================================================
# SPECIFIC RESTORATION
#=================================================
Expand Down
10 changes: 10 additions & 0 deletions scripts/upgrade
Expand Up @@ -58,6 +58,16 @@ fi

#=================================================
# SPECIFIC UPGRADE
#=================================================
# STRETCH COMPATIBILITY
#=================================================

if is_stretch
then
ynh_replace_string "yunohost backup create --ignore-apps" "yunohost backup create" "$final_path/archivist.sh"
ynh_replace_string "yunohost backup create --ignore-system" "yunohost backup create" "$final_path/archivist.sh"
fi

#=================================================
# UPDATE THE CRON FILE
#=================================================
Expand Down

0 comments on commit 8ac40c5

Please sign in to comment.