diff options
Diffstat (limited to 'lib/sisu/v4')
-rw-r--r-- | lib/sisu/v4/options.rb | 10 | ||||
-rw-r--r-- | lib/sisu/v4/sysenv.rb | 44 |
2 files changed, 7 insertions, 47 deletions
diff --git a/lib/sisu/v4/options.rb b/lib/sisu/v4/options.rb index 39c392a9..d2898bfd 100644 --- a/lib/sisu/v4/options.rb +++ b/lib/sisu/v4/options.rb @@ -59,7 +59,7 @@ module SiSU_Commandline require 'pathname' require_relative 'sysenv' # sysenv.rb - @@base_path=nil + @@sisu_call_origin_path=nil class Options attr_accessor :cmd,:mod,:act,:dir_structure_by,:f_pths,:files,:files_mod,:base_path,:base_stub,:sub_location,:paths,:lngs,:f_pth,:pth,:fno,:fns,:fnb,:fnc,:fng,:fncb,:lng,:lng_base,:what @@act=nil @@ -69,8 +69,8 @@ module SiSU_Commandline @env=SiSU_Env::InfoEnv.new @lng_base=@env.language_default_set @dir_structure_by=SiSU_Env::EnvCall.new.output_dir_structure.by? - @@base_path ||=Dir.pwd - @base_path=@@base_path + @@sisu_call_origin_path ||=Dir.pwd + @base_path=@@sisu_call_origin_path r=Px[:lng_lst_rgx] u=/.+?\/([^\/]+)(?:\/(?:#{r})$|$)/ @base_stub=@base_path.gsub(u,'\1') @@ -181,9 +181,9 @@ module SiSU_Commandline @lngs = q[:lngs] if @files.length > 0 \ and @cmd.empty? \ - and @mod.length==0 #% if no other action called on filename given, default is sisu --v3 -0 [filename(s)] configured as flag default + and @mod.length==0 #% if no other action called on filename given, default is sisu --v4 -0 [filename(s)] configured as flag default shortcut=SiSU_Env::InfoProcessingFlag.new - @mod=['--v3'] + @mod=['--v4'] @cmd=shortcut.cf_0 + 'm' end if @cmd =~/[vVM]/ \ diff --git a/lib/sisu/v4/sysenv.rb b/lib/sisu/v4/sysenv.rb index c4b364ad..90df10fa 100644 --- a/lib/sisu/v4/sysenv.rb +++ b/lib/sisu/v4/sysenv.rb @@ -5668,48 +5668,8 @@ WOK end @skin_apply end - def select # skin loading logic here - load "#{SiSU_lib}/defaults.rb" - skin_path=[] - @env.sys.rc_path.each {|x| skin_path << "#{x}/skin"} - skin_path << "#{@env.processing_path.processing}/external_document/skin" - skin=if @pwd_stub =~/^(?:doc|sisupod)$/ \ - and ((! @md.nil?) \ - && (defined? @md.opt) \ - && (defined? @md.opt.mod) \ - && @md.opt.mod.inspect !~/--trust/) - true # security only run skins on sisupod if --trust flag is provided - elsif @pwd_stub =~/^(?:doc|sisupod)$/ # consider/reconsider doc - false - else true - end - doc_skin,dir_skin=nil,nil - if skin - unless @d_sk.nil? - sk_doc="doc/#{@d_sk}.rb" - skin_path.each do |v| # document skin priority 1 - if FileTest.file?("#{v}/#{sk_doc}") - doc_skin="#{v}/#{sk_doc}" - load doc_skin - break - end - end - end - unless doc_skin - sk_dir="dir/skin_#{@pwd_stub}.rb" - skin_path.each do |v| # directory skin priority 2 - if FileTest.file?("#{v}/#{sk_dir}") - dir_skin="#{v}/#{sk_dir}" - load dir_skin - break - end - end - end - end - sk=if doc_skin; doc_skin - elsif dir_skin; dir_skin - else nil - end + def select # skin loading logic here, removed + nil end end class CSS_Default |