rulp 0.0.11 → 0.0.12

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- YWE1OGM4NzNhYjNkODZkZWNlZjJhMmYzMTgxZDQyOTFhZjViZWIyZg==
4
+ YmU0YjdmMjllMmU1YWJlMWM1MDNiMmM1OTc5YjNlMmYxN2ViMjg3OA==
5
5
  data.tar.gz: !binary |-
6
- ODQxYjk4YzE3MjRmNDFhODgyMDFiZTgxZjJiMzkyNzk1MjYzM2EwNg==
6
+ MjM3MDZmYmY4NmZjNzI1ZmYzOTk3ZjYzNTQxMDAzYTk2OGFjY2FmMg==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- MGNmNDU5NGU0NDhhZGE1ZWM2Mjc4MjIwYTNmNWU2N2Q1ZmE5NTc0NGI4YjJh
10
- MzZkY2NjMWI0ZTQ5NDRhNTQ5ZmM5NmJlMWM2M2Q0ZGU5MTdhOTBkMzliNTc1
11
- MzViNmYyYWVhZWNlODdiNDUzMTQxZmMxNWIxYmUwZWU3ODRlZjk=
9
+ NGY4YTJjOWNkOWNiNDNlMjU1ZjM0Njg0ZGE4YzFkYjhkMTYxMTg0ODMzMjQx
10
+ M2NiOWYyMWI5YTc4NDZlOWQ2ZmZmYzZlYzAxMjM0OTAyMjRiOGY1ZmJlOGVh
11
+ Mjc4MjRiMTQ4OGZiZWQ3NjMxOTg5NGY2NmFhZmU3YzJiZjNmZGE=
12
12
  data.tar.gz: !binary |-
13
- NzM4ZDhjNzZhNTFhOTMwZTAyNDViODM2Yjk5ZjY0NmY1NDk4MTk0ZDNjZjZk
14
- ZGNlZDk4YzI2YzBlNGI0ODFlYjcyY2QzZjE4OWI5ZGIxMTlhM2JjZGQzNzBk
15
- MWZhNmI1YmExYzIzZDVhYmY0Mzg3NGRmNWI4MWMyNzBkNDUwYzA=
13
+ YmVjYWJiNzFhZDliZmM4MWNlMDAzMjk4OGM2MGQ5ZGMzNDBiODZkNzk5MjM4
14
+ Yjk3M2RmZWRiYjVhNmJlMDY5ZTUwOTAzNWEwMGM4YWIzNzQwNzIyMDhjYjIx
15
+ MTZlZTYzY2M0NzY1M2YzYWI5NzZhZGViZDcyMzY0MjYwYzI2MGM=
data/lib/rulp/rulp.rb CHANGED
@@ -151,7 +151,7 @@ module Rulp
151
151
  "Solving problem".log(:info)
152
152
  _, time = _profile{ solver.solve(open_solution) }
153
153
 
154
- "Solver took #{time}".log(:info)
154
+ "Solver took #{time}".log(:debug)
155
155
 
156
156
  "Parsing result".log(:info)
157
157
  solver.store_results(@variables)
@@ -1,11 +1,15 @@
1
1
  class Solver
2
2
  def initialize(filename)
3
3
  @filename = filename
4
- @outfile = "/tmp/#{executable}-output.txt"
4
+ @outfile = get_output_filename
5
5
  raise StandardError.new("Couldn't find solver #{executable}!") if `which #{executable}`.length == 0
6
6
  @solver_exists = true
7
7
  end
8
8
 
9
+ def get_output_filename
10
+ "/tmp/rulp-#{Random.rand(0..1000)}.sol"
11
+ end
12
+
9
13
  def store_results(variables)
10
14
  puts "Not yet implemented"
11
15
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rulp
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.11
4
+ version: 0.0.12
5
5
  platform: ruby
6
6
  authors:
7
7
  - Wouter Coppieters
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-03-30 00:00:00.000000000 Z
11
+ date: 2015-04-01 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: A simple Ruby LP description DSL
14
14
  email: wc@pico.net.nz