Commit 5a4f284e6773802f368cc84de9c57865c6356baa
1 parent
01c0f483
Exists in
master
and in
29 other branches
revert some changes made by commit '3d1796'
Showing
1 changed file
with
4 additions
and
9 deletions
Show diff stats
script/noosfero-plugins
... | ... | @@ -77,8 +77,7 @@ run(){ |
77 | 77 | |
78 | 78 | _enable(){ |
79 | 79 | plugin="$1" |
80 | - cd $enabled_plugins_dir | |
81 | - source="../../plugins/$plugin" | |
80 | + source="$available_plugins_dir/$plugin" | |
82 | 81 | target="$enabled_plugins_dir/$plugin" |
83 | 82 | base="$base_plugins_dir/$plugin" |
84 | 83 | run "$source/before_enable.rb" |
... | ... | @@ -101,15 +100,11 @@ _enable(){ |
101 | 100 | fi |
102 | 101 | fi |
103 | 102 | if [ "$installation_ok" = true ] && [ "$dependencies_ok" = true ]; then |
104 | - ln -s "$source" "$plugin" | |
103 | + ln -s "$source" "$target" | |
105 | 104 | plugins_public_dir="$NOOSFERO_DIR/public/plugins" |
106 | 105 | plugins_features_dir="$NOOSFERO_DIR/features/plugins" |
107 | - cd $plugins_public_dir | |
108 | - test -d "$source/public" && ln -s "$source/public" "$plugin" | |
109 | - if [ -d "$NOOSFERO_DIR/features" ]; then | |
110 | - cd $plugins_features_dir | |
111 | - test -d "$source/features" && ln -s "$source/features" "$plugin" | |
112 | - fi | |
106 | + test -d "$target/public" && ln -s "$target/public" "$plugins_public_dir/$plugin" | |
107 | + test -d "$NOOSFERO_DIR/features" && test -d "$target/features" && ln -s "$target/features" "$plugins_features_dir/$plugin" | |
113 | 108 | _say "$plugin enabled" |
114 | 109 | run "$source/after_enable.rb" |
115 | 110 | needs_migrate=true | ... | ... |