• R/O
  • HTTP
  • SSH
  • HTTPS

crshini: Commit

GitHubのミラーです
https://github.com/hayao0819/crshini


Commit MetaInfo

Révision99d2925aa11940d00c21a0267e4d64054e942ef7 (tree)
l'heure2021-06-08 21:48:26
Auteurhayao <hayao@fasc...>
Commiterhayao

Message de Log

[fix] : Fixed for array

Change Summary

Modification

--- a/src/libcrshini
+++ b/src/libcrshini
@@ -200,8 +200,7 @@ _crshini_set(){
200200 # --merge command
201201 _crshini_merge(){
202202 # Set variables
203- local _crshini_merge_file="${1}" _crshini_merge_section="${2-""}" _crshini_merge_source __section _crshini_merge_sectionlist=()
204- _crshini_merge_source="$(cat -)"
203+ local _crshini_merge_file="${1}" _crshini_merge_section="${2-""}" _crshini_merge_source __section _crshini_merge_sectionlist=() _crshini_merge_source="$(cat -)"
205204
206205 # Get sections
207206 if [[ -z "${_crshini_merge_section}" ]]; then
@@ -263,7 +262,7 @@ _crshini_del(){
263262
264263 if [[ "${_crshini_del_insection}" = false ]]; then
265264 _crshini_del_lineout=true # 出力する
266- elif [[ -z "${_crshini_del_param}" ]]; then #あとで配列版に書き直す
265+ elif (( "${#_crshini_del_param[@]}" == 0 )); then
267266 _crshini_del_lineout=false # セクション内にいて、パラメータが設定されていないので出力しない
268267 else
269268 for __param in "${_crshini_del_param[@]}"; do
Afficher sur ancien navigateur de dépôt.