1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/weblate_ynh.git synced 2024-10-01 13:35:04 +02:00

fix hub config

This commit is contained in:
ericgaspar 2022-08-11 20:50:47 +02:00
parent 58ca24f71b
commit 38111e8433
3 changed files with 15 additions and 21 deletions

View file

@ -1,4 +1,4 @@
__FORGE_WEBSITE__:
github.com:
- user: __FORGE_USERNAME__
oauth_token: __FORGE_TOKEN__
protocol: https

View file

@ -130,20 +130,17 @@ ynh_secure_remove --file="$tempdir"
#=================================================
# CONFIGURE HUB
#=================================================
ynh_script_progression --message="Configure hub..." --weight=1
if [ $used_forge = "GitHub" ] ; then
forge_website="github.com"
else
forge_website="gitlab.com"
fi
ynh_script_progression --message="Configure hub..." --weight=1
mkdir "$final_path/.config/"
ynh_add_config --template="../conf/hub_config" --destination="$final_path/.config/hub"
mkdir "$final_path/.config/"
ynh_add_config --template="../conf/hub_config" --destination="$final_path/.config/hub"
cat <<EOF > "$final_path/.bashrc"
eval "$(hub alias -s /bin/bash)"
cat <<EOF > "$final_path/.bashrc"
eval "$(hub alias -s /bin/bash)"
EOF
fi
#=================================================
# PIP INSTALLATION

View file

@ -139,20 +139,17 @@ ynh_secure_remove --file="$tempdir"
#=================================================
# CONFIGURE HUB
#=================================================
ynh_script_progression --message="Configure hub..." --weight=2
if [ $used_forge = "GitHub" ] ; then
forge_website="github.com"
else
forge_website="gitlab.com"
fi
ynh_script_progression --message="Configure hub..." --weight=1
mkdir "$final_path/.config/"
ynh_add_config --template="../conf/hub_config" --destination="$final_path/.config/hub"
mkdir -p "$final_path/.config/"
ynh_add_config --template="../conf/hub_config" --destination="$final_path/.config/hub"
cat <<EOF > "$final_path/.bashrc"
eval "$(hub alias -s /bin/bash)"
cat <<EOF > "$final_path/.bashrc"
eval "$(hub alias -s /bin/bash)"
EOF
fi
#=================================================
# UPDATE A CONFIG FILE