Sha256: 66ee506c616fbc9ec6fcc41f4f721cb91c2e6aa9223d10f5622d4fb2940d86a4

Contents?: true

Size: 858 Bytes

Versions: 21

Compression:

Stored size: 858 Bytes

Contents

#!/usr/bin/env ruby

require 'rbbt-util'
require 'rbbt/util/simpleopt'
require 'rbbt/hpc'

#$0 = "rbbt #{$previous_commands*""} #{ File.basename(__FILE__) }" if $previous_commands

options = SOPT.setup <<EOF

Queue a job in Marenostrum

$ rbbt slurm tail <directory> [options] 

-h--help Print this help
EOF

if options[:help]
 if defined? rbbt_usage
  rbbt_usage 
 else
  puts SOPT.doc
 end
 exit 0
end

batch_system = options.delete :batch_system
batch_system ||= 'auto'

HPC::BATCH_MODULE = HPC.batch_system batch_system

raise ParameterException.new("Could not detect batch_system: #{Misc.fingerprint batch_system}") if HPC::BATCH_MODULE.nil?

directory = ARGV.shift

raise ParameterException if directory.nil?

directory = File.dirname(directory) unless File.directory?(directory)

require 'rbbt/hpc/slurm'

HPC::BATCH_MODULE.follow_job directory, true

Version data entries

21 entries across 7 versions & 1 rubygems

Version Path
rbbt-util-5.33.4 share/rbbt_commands/hpc/tail
rbbt-util-5.33.4 share/rbbt_commands/slurm/tail
rbbt-util-5.33.4 share/rbbt_commands/lsf/tail
rbbt-util-5.33.3 share/rbbt_commands/slurm/tail
rbbt-util-5.33.3 share/rbbt_commands/lsf/tail
rbbt-util-5.33.3 share/rbbt_commands/hpc/tail
rbbt-util-5.33.2 share/rbbt_commands/lsf/tail
rbbt-util-5.33.2 share/rbbt_commands/hpc/tail
rbbt-util-5.33.2 share/rbbt_commands/slurm/tail
rbbt-util-5.33.1 share/rbbt_commands/lsf/tail
rbbt-util-5.33.1 share/rbbt_commands/hpc/tail
rbbt-util-5.33.1 share/rbbt_commands/slurm/tail
rbbt-util-5.33.0 share/rbbt_commands/slurm/tail
rbbt-util-5.33.0 share/rbbt_commands/lsf/tail
rbbt-util-5.33.0 share/rbbt_commands/hpc/tail
rbbt-util-5.32.30 share/rbbt_commands/hpc/tail
rbbt-util-5.32.30 share/rbbt_commands/slurm/tail
rbbt-util-5.32.30 share/rbbt_commands/lsf/tail
rbbt-util-5.32.28 share/rbbt_commands/lsf/tail
rbbt-util-5.32.28 share/rbbt_commands/slurm/tail