<commit_before>Capistrano::Configuration.instance.load do
  namespace :puma do
    namespace :upstart do
      %w(start stop status).each do |t|
        desc "Perform #{t} of the api_puma service"
        task t, roles: :app, except: { no_release: true } do
          sudo "#{t} api_puma"
        end
      end

      desc 'Perform a restart of the api_puma service'
      task :restart, roles: :app, except: { no_release: true } do
        run <<-CMD
          pid=`status api_puma | grep -o -E '[0-9]+'`;
          if [ -z $pid ]; then
            sudo start api_puma;
          else
            kill -USR1 $pid;
          fi
        CMD
      end
    end
  end
end
<commit_msg>Allow application name configuration, use reload<commit_after>Capistrano::Configuration.instance.load do
  set(:puma_application_name) { "#{application}_puma" }
  namespace :puma do
    namespace :upstart do
      %w(reload start stop status).each do |t|
        desc "Perform #{t} of the _puma service"
        task t, roles: :app, except: { no_release: true } do
          sudo "#{t} #{puma_application_name}"
        end
      end

      desc 'Perform a restart of the application puma service'
      task :restart, roles: :app, except: { no_release: true } do
        run <<-CMD
          pid=`status #{puma_application_name} | grep -o -E '[0-9]+'`;
          if [ -z $pid ]; then
            sudo start #{puma_application_name};
          else
            sudo reload #{puma_application_name};
          fi
        CMD
      end
    end
  end
end

{'fraction_non_alphanumeric': 0.10378590078328982, 'fraction_numerical': 0.0032637075718015664, 'mean_word_length': 2.0236686390532546, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1336531', 'n_tokens_mistral': 489, 'n_tokens_neox': 473, 'n_words': 157}