diff options
Diffstat (limited to 'Master/texmf-dist/scripts/epspdf/epspdfrc.rb')
-rwxr-xr-x | Master/texmf-dist/scripts/epspdf/epspdfrc.rb | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/Master/texmf-dist/scripts/epspdf/epspdfrc.rb b/Master/texmf-dist/scripts/epspdf/epspdfrc.rb index 66ecdb8c1d6..a6ea573cf11 100755 --- a/Master/texmf-dist/scripts/epspdf/epspdfrc.rb +++ b/Master/texmf-dist/scripts/epspdf/epspdfrc.rb @@ -1,10 +1,10 @@ -EPVERSION = '0.5.2' -COPYRIGHT = '2006, 2008, 2009, 2010' +EPVERSION = '0.5.3' +COPYRIGHT = '2006, 2008, 2009, 2010, 2011' # epspdf conversion utility, configuration module ##### -# Copyright (C) 2006, 2008, 2009, 2010 Siep Kroonenberg +# Copyright (C) 2006, 2008, 2009, 2010, 2011 Siep Kroonenberg # n dot s dot kroonenberg at rug dot nl # # This program is free software, licensed under the GNU GPL, >=2.0. @@ -119,11 +119,16 @@ end # def # system-dependent location of logfile -epsdir = case ARCH +epsdir = '' +case ARCH when 'w32' - "#{ENV['APPDATA'].gsub( /\\/, '/' )}/epspdf" + Registry::HKEY_CURRENT_USER.open( 'Software\Microsoft\Windows' + + '\CurrentVersion\Explorer\User Shell Folders' ) do |r| + epsdir = r.read_s_expand( 'AppData' ) + end + epsdir = "#{epsdir.gsub( /\\/, '/' )}/epspdf" else - "#{ENV['HOME']}/.epspdf" + epsdir = "#{ENV['HOME']}/.epspdf" end Dir.mkdir( epsdir ) unless test( ?e, epsdir ) # epsdir may be a regular file, or creation above may have failed |