From a992c5fbc218ed8c813240e75b153fed92ef53be Mon Sep 17 00:00:00 2001 From: maxwell <maxwell@joindiaspora.com> Date: Mon, 25 Oct 2010 22:03:36 -0700 Subject: [PATCH] dont show service if you dont have the keys for it. also, update deploy script --- app/views/services/index.html.haml | 4 ++-- config/deploy.rb | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/app/views/services/index.html.haml b/app/views/services/index.html.haml index ea375e9ac6..5bec559336 100644 --- a/app/views/services/index.html.haml +++ b/app/views/services/index.html.haml @@ -23,6 +23,6 @@ = service.nickname = link_to "disconnect", service, :confirm => "disconnect #{service.provider}?", :method => :delete - %h4= link_to "Connect to twitter", "/auth/twitter" - %h4= link_to "Connect to facebook", "/auth/facebook" + %h4= link_to "Connect to twitter", "/auth/twitter" if SERVICES['twitter']['consumer_key']!= "" + %h4= link_to "Connect to facebook", "/auth/facebook" if SERVICES['facebook']['app_id'] !="" diff --git a/config/deploy.rb b/config/deploy.rb index b4893ec937..09d8c0bc31 100644 --- a/config/deploy.rb +++ b/config/deploy.rb @@ -56,9 +56,9 @@ namespace :deploy do run "ln -s -f #{shared_path}/app_config.yml #{current_path}/config/app_config.yml" end - task :symlink_fb_config do - run "touch #{shared_path}/fb_config.yml" - run "ln -s -f #{shared_path}/fb_config.yml #{current_path}/config/fb_config.yml" + task :symlink_oauth_keys_config do + run "touch #{shared_path}/oauth_keys.yml" + run "ln -s -f #{shared_path}/oauth_keys.yml #{current_path}/config/oauth_keys.yml" end task :start do @@ -157,4 +157,4 @@ namespace :db do end -after "deploy:symlink", "deploy:symlink_images", "deploy:symlink_bundle", 'deploy:symlink_config', 'deploy:symlink_fb_config' +after "deploy:symlink", "deploy:symlink_images", "deploy:symlink_bundle", 'deploy:symlink_config', 'deploy:symlink_oauth_keys_config' -- GitLab