Bob Mottram 7 年 前
コミット
ed9fb5bc4a
共有2 個のファイルを変更した6 個の追加9 個の削除を含む
  1. 4
    1
      src/freedombone-app-pelican
  2. 2
    8
      src/freedombone-mesh-blog

+ 4
- 1
src/freedombone-app-pelican ファイルの表示

@@ -332,7 +332,10 @@ function pelican_change_theme {
332 332
     CHOSEN_THEME_INDEX=$((CHOSEN_THEME_INDEX - 1))
333 333
 
334 334
     CHOSEN_THEME=${THEMES[$CHOSEN_THEME_INDEX]}
335
-    pelican_remove_bad_blog_links $CHOSEN_THEME
335
+
336
+    cd $PELICAN_BLOG_INSTALL_DIR/themes/$CHOSEN_THEME
337
+    pelican_remove_bad_blog_links
338
+
336 339
     if grep -q "THEME=" $PELICAN_BLOG_INSTALL_DIR/pelicanconf.py; then
337 340
         sed -i "s|THEME=.*|THEME='themes/${CHOSEN_THEME}'|g" $PELICAN_BLOG_INSTALL_DIR/pelicanconf.py
338 341
     else

+ 2
- 8
src/freedombone-mesh-blog ファイルの表示

@@ -50,13 +50,6 @@ function remove_bad_blog_links {
50 50
     find ./ -type f -name *.html -exec sed -i -e '/bootstrapcdn/d' {} \;
51 51
 }
52 52
 
53
-function remove_bad_blog_links_from_theme {
54
-    current_theme=$1
55
-
56
-    cd $BLOG_PATH/themes/$current_theme
57
-    remove_bad_blog_links
58
-}
59
-
60 53
 function ipfs_publish {
61 54
     DIR_TO_CHECK=/home/$USER/Public
62 55
     if [ ! -d $DIR_TO_CHECK ]; then
@@ -219,7 +212,8 @@ function change_theme {
219 212
     CHOSEN_THEME_INDEX=$((CHOSEN_THEME_INDEX - 1))
220 213
 
221 214
     CHOSEN_THEME=${THEMES[$CHOSEN_THEME_INDEX]}
222
-    remove_bad_blog_links_from_theme $CHOSEN_THEME
215
+    cd cd $BLOG_PATH/themes/$CHOSEN_THEME
216
+    remove_bad_blog_links
223 217
     if grep -q "THEME=" $BLOG_PATH/pelicanconf.py; then
224 218
         sed -i "s|THEME=.*|THEME='themes/${CHOSEN_THEME}'|g" $BLOG_PATH/pelicanconf.py
225 219
     else