You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@whimsical.apache.org by ru...@apache.org on 2018/05/08 17:12:58 UTC
[whimsy] branch master updated: eliminate dependency on bundler
This is an automated email from the ASF dual-hosted git repository.
rubys pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/whimsy.git
The following commit(s) were added to refs/heads/master by this push:
new c6c867a eliminate dependency on bundler
c6c867a is described below
commit c6c867a45e40a2966f94964c9b86b0f0f577ef3f
Author: Sam Ruby <ru...@intertwingly.net>
AuthorDate: Tue May 8 13:12:46 2018 -0400
eliminate dependency on bundler
---
www/board/agenda/daemon/wsc.rb | 2 +-
www/board/agenda/daemon/wss.rb | 3 +--
2 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/www/board/agenda/daemon/wsc.rb b/www/board/agenda/daemon/wsc.rb
index 0fdc1ce..dfc8e68 100644
--- a/www/board/agenda/daemon/wsc.rb
+++ b/www/board/agenda/daemon/wsc.rb
@@ -1,5 +1,5 @@
#!/usr/bin/env ruby
-require 'bundler/setup'
+$:.unshift File.realpath(File.expand_path('../' * 5 + 'lib', __FILE__))
require 'websocket-client-simple'
require 'optparse'
require 'ostruct'
diff --git a/www/board/agenda/daemon/wss.rb b/www/board/agenda/daemon/wss.rb
index 716b62e..37b693f 100755
--- a/www/board/agenda/daemon/wss.rb
+++ b/www/board/agenda/daemon/wss.rb
@@ -1,6 +1,5 @@
#!/usr/bin/env ruby
-Dir.chdir __dir__
-require 'bundler/setup'
+$:.unshift File.realpath(File.expand_path('../' * 5 + 'lib', __FILE__))
require 'websocket-eventmachine-server'
require 'listen'
require 'ostruct'
--
To stop receiving notification emails like this one, please contact
rubys@apache.org.
Re: [whimsy] branch master updated: eliminate dependency on bundler
Posted by sebb <se...@gmail.com>.
On 8 May 2018 at 18:12, <ru...@apache.org> wrote:
> This is an automated email from the ASF dual-hosted git repository.
>
> rubys pushed a commit to branch master
> in repository https://gitbox.apache.org/repos/asf/whimsy.git
>
>
> The following commit(s) were added to refs/heads/master by this push:
> new c6c867a eliminate dependency on bundler
> c6c867a is described below
>
> commit c6c867a45e40a2966f94964c9b86b0f0f577ef3f
> Author: Sam Ruby <ru...@intertwingly.net>
> AuthorDate: Tue May 8 13:12:46 2018 -0400
>
> eliminate dependency on bundler
> ---
> www/board/agenda/daemon/wsc.rb | 2 +-
> www/board/agenda/daemon/wss.rb | 3 +--
> 2 files changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/www/board/agenda/daemon/wsc.rb b/www/board/agenda/daemon/wsc.rb
> index 0fdc1ce..dfc8e68 100644
> --- a/www/board/agenda/daemon/wsc.rb
> +++ b/www/board/agenda/daemon/wsc.rb
> @@ -1,5 +1,5 @@
> #!/usr/bin/env ruby
> -require 'bundler/setup'
> +$:.unshift File.realpath(File.expand_path('../' * 5 + 'lib', __FILE__))
> require 'websocket-client-simple'
> require 'optparse'
> require 'ostruct'
> diff --git a/www/board/agenda/daemon/wss.rb b/www/board/agenda/daemon/wss.rb
> index 716b62e..37b693f 100755
> --- a/www/board/agenda/daemon/wss.rb
> +++ b/www/board/agenda/daemon/wss.rb
> @@ -1,6 +1,5 @@
> #!/usr/bin/env ruby
> -Dir.chdir __dir__
> -require 'bundler/setup'
> +$:.unshift File.realpath(File.expand_path('../' * 5 + 'lib', __FILE__))
I tried removing the equivalent line from test/example.cgi and it failed.
I then added the following to httpd config
SetEnv RUBYLIB=/srv/whimsy/lib
restarted, and it worked again
Of course that assumes whimsy is installed under /srv, but it is a
simple alternative, at least for CGIs.
> require 'websocket-eventmachine-server'
> require 'listen'
> require 'ostruct'
>
> --
> To stop receiving notification emails like this one, please contact
> rubys@apache.org.