File tree 5 files changed +12
-3
lines changed
5 files changed +12
-3
lines changed Original file line number Diff line number Diff line change 1
1
#!/usr/bin/env ruby
2
2
require 'qrtrx'
3
- Qrtrx ::Server . new . start
3
+ if ARGV . size == 1
4
+ Qrtrx ::Server . new ( ARGV . shift ) . start
5
+ else
6
+ puts 'Invalid arguments. Example usage: `qrtrx file_to_share.jpg`'
7
+ end
Original file line number Diff line number Diff line change 5
5
6
6
module Qrtrx
7
7
class Server
8
- def initialize ( file_name = 'test.txt' )
8
+ def initialize ( file_name )
9
9
@file_name = file_name
10
+ # TODO - check file presence
11
+ # TODO - support directories (zip?)
12
+ # TODO - support directories outside the current one?
13
+ # TODO - readme (with screenshots), reference to original proj
10
14
end
11
15
12
16
def start
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ Gem::Specification.new do |spec|
27
27
f . match ( %r{^(test|spec|features)/} )
28
28
end
29
29
spec . bindir = "exe"
30
- spec . executables = spec . files . grep ( %r{^exe/} ) { | f | File . basename ( f ) }
30
+ spec . executables = [ "qrtrx" ]
31
31
spec . require_paths = [ "lib" ]
32
32
33
33
spec . add_development_dependency "bundler" , "~> 1.16"
Original file line number Diff line number Diff line change
1
+ THIS IS MY FILE!
You can’t perform that action at this time.
0 commit comments