• R/O
  • HTTP
  • SSH
  • HTTPS

osdn-cli: Commit


Commit MetaInfo

Revisión06fb6dcc777c54c72ced5945e26b6542c35c9296 (tree)
Tiempo2017-05-01 14:05:48
AutorTatsuki Sugiura <sugi@nemu...>
CommiterTatsuki Sugiura

Log Message

Runnable on win32 environment.

Cambiar Resumen

Diferencia incremental

--- a/lib/osdn/cli.rb
+++ b/lib/osdn/cli.rb
@@ -70,7 +70,7 @@ module OSDN
7070 logger.error "Invalid ownership of credential file #{credential_path}, skip loading."
7171 return
7272 end
73- unless (stat.mode & 0777).to_s(8) == "600"
73+ if RUBY_PLATFORM !~ /mswin|msys|mingw|cygwin|bccwin|wince|emc/ && (stat.mode & 0777).to_s(8) != "600"
7474 logger.error "Invalid permission #{(stat.mode & 0777).to_s(8)} of credential file #{credential_path}, skip loading."
7575 return
7676 end
--- a/lib/osdn/cli/command/login.rb
+++ b/lib/osdn/cli/command/login.rb
@@ -42,7 +42,7 @@ module OSDN; module CLI; module Command
4242 end
4343 case RUBY_PLATFORM
4444 when /mswin|msys|mingw|cygwin|bccwin|wince|emc/
45- exec("start #{url}") if fork.nil?
45+ spawn("start #{url.gsub(/&/, '^&')}")
4646 when /darwin|mac os/
4747 exec("/usr/bin/open", url) if fork.nil?
4848 end
Show on old repository browser