Commit 5a4f284e6773802f368cc84de9c57865c6356baa

Authored by Joenio Costa
1 parent 01c0f483

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,8 +77,7 @@ run(){
77 77
78 _enable(){ 78 _enable(){
79 plugin="$1" 79 plugin="$1"
80 - cd $enabled_plugins_dir  
81 - source="../../plugins/$plugin" 80 + source="$available_plugins_dir/$plugin"
82 target="$enabled_plugins_dir/$plugin" 81 target="$enabled_plugins_dir/$plugin"
83 base="$base_plugins_dir/$plugin" 82 base="$base_plugins_dir/$plugin"
84 run "$source/before_enable.rb" 83 run "$source/before_enable.rb"
@@ -101,15 +100,11 @@ _enable(){ @@ -101,15 +100,11 @@ _enable(){
101 fi 100 fi
102 fi 101 fi
103 if [ "$installation_ok" = true ] && [ "$dependencies_ok" = true ]; then 102 if [ "$installation_ok" = true ] && [ "$dependencies_ok" = true ]; then
104 - ln -s "$source" "$plugin" 103 + ln -s "$source" "$target"
105 plugins_public_dir="$NOOSFERO_DIR/public/plugins" 104 plugins_public_dir="$NOOSFERO_DIR/public/plugins"
106 plugins_features_dir="$NOOSFERO_DIR/features/plugins" 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 _say "$plugin enabled" 108 _say "$plugin enabled"
114 run "$source/after_enable.rb" 109 run "$source/after_enable.rb"
115 needs_migrate=true 110 needs_migrate=true