<commit_before># $Id$


if PROJ.bzr and system("bzr --version 2>&1 > #{DEV_NULL}")

namespace :bzr do

  desc 'Show tags of this branch'
  task :show_tags do |t|
    tags = %x{bzr tags}
    puts tags
  end

  desc 'Create a new tag in this branch'
  task :create_tag do |t|
    v = ENV['VERSION'] or abort 'Must supply VERSION=x.y.z'
    abort "Versions don't match #{v} vs #{PROJ.version}" if v != PROJ.version

    tag = "%s-%s" % [PROJ.name, PROJ.version]

    puts "Creating bzr tag '#{tag}'"
    unless system("bzr tag #{tag}")
      abort "Tag creation failed"
    end
  end

  desc "Write bzr changelog to file #{PROJ.changes_file}"
  task :changelog => [PROJ.changelog]
  file PROJ.changelog => [".bzr/branch/last-revision"] do |t|
    ["gnu", "long"].each do |f|
      sh("bzr log --log-format=#{f} --verbose >#{t.name}") do |ok, result|
      end

      break if 0 == $?
    end
  end

end  # namespace :bzr

desc 'Alias to bzr:changelog'
task 'changelog' => 'bzr:changelog'

task 'gem:release' => 'bzr:create_tag'

end  # if PROJ.svn

# EOF<commit_msg>Forgotten rename of PROJ.changes_file to PROJ.changelog.<commit_after># $Id$


if PROJ.bzr and system("bzr --version 2>&1 > #{DEV_NULL}")

namespace :bzr do

  desc 'Show tags of this branch'
  task :show_tags do |t|
    tags = %x{bzr tags}
    puts tags
  end

  desc 'Create a new tag in this branch'
  task :create_tag do |t|
    v = ENV['VERSION'] or abort 'Must supply VERSION=x.y.z'
    abort "Versions don't match #{v} vs #{PROJ.version}" if v != PROJ.version

    tag = "%s-%s" % [PROJ.name, PROJ.version]

    puts "Creating bzr tag '#{tag}'"
    unless system("bzr tag #{tag}")
      abort "Tag creation failed"
    end
  end

  desc "Write bzr changelog to file #{PROJ.changelog}"
  task :changelog => [PROJ.changelog]
  file PROJ.changelog => [".bzr/branch/last-revision"] do |t|
    ["gnu", "long"].each do |f|
      sh("bzr log --log-format=#{f} --verbose >#{t.name}") do |ok, result|
      end

      break if 0 == $?
    end
  end

end  # namespace :bzr

desc 'Alias to bzr:changelog'
task 'changelog' => 'bzr:changelog'

task 'gem:release' => 'bzr:create_tag'

end  # if PROJ.svn

# EOF
{'fraction_non_alphanumeric': 0.15650969529085873, 'fraction_numerical': 0.002770083102493075, 'mean_word_length': 3.020408163265306, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 17, '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': '7411279', 'n_tokens_mistral': 878, 'n_tokens_neox': 844, 'n_words': 256}