File: app2.rb

package info (click to toggle)
libcommandline-ruby 0.7.10-6
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 556 kB
  • ctags: 289
  • sloc: ruby: 2,881; makefile: 5
file content (17 lines) | stat: -rwxr-xr-x 305 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/usr/bin/env ruby
require 'rubygems'
require 'commandline'

class App < CommandLine::Application

  def initialize
    synopsis "[-dh] file"
    expected_args :file
  end

  def main
    puts "#{name} called with #{args.size} arguments: #{args.inspect}"
    puts "@file = #{@file}"
  end

end#class App