Commit 5777eff9a4a3cb92ac88567a19feb99a634388c7

Thomas de Grivel 2023-02-20T21:14:50

fix startup

diff --git a/bin/rbpkg b/bin/rbpkg
index 0c38b07..588fe41 100755
--- a/bin/rbpkg
+++ b/bin/rbpkg
@@ -1,13 +1,14 @@
 #!/usr/bin/env ruby
 require __FILE__ + '/../../lib/rbpkg'
 
-Rbpkg.init()
-Rbpkg.lock("rbpkg")
-
 log_path = Rbpkg.log_path("rbpkg")
+FileUtils.mkdir_p(File.dirname(log_path))
 $log = File.open(log_path, "w")
 #verbose 2, "Logging to #{log_path}"
 
+Rbpkg.init()
+Rbpkg.lock("rbpkg")
+
 def usage()
   STDERR.puts """Usage: #{File.basename($0)} COMMAND REPO ...