diff --git a/add_lib_ppl/pkgmeta.ltn b/add_lib_ppl/pkgmeta.ltn deleted file mode 100644 index 34aab64..0000000 --- a/add_lib_ppl/pkgmeta.ltn +++ /dev/null @@ -1,13 +0,0 @@ -{ - ["version"] = "0.1.0-3", - ["dependencies"] = { - - }, - ["description"] = "Makes require look in /lib and shell look in /bin. Don't ask how. You really don't want to know.", - ["files"] = { - ["startup"] = { - ".__add_lib_ppl.lua" - } - }, - ["restart_on_inst"]=1, -} diff --git a/add_lib_ppl/startup/.__add_lib_ppl.lua b/add_lib_ppl/startup/.__add_lib_ppl.lua deleted file mode 100644 index c9bff78..0000000 --- a/add_lib_ppl/startup/.__add_lib_ppl.lua +++ /dev/null @@ -1,25 +0,0 @@ -local function loader(mn) - local at=nil - if fs.exists("/lib/"..mn..".lua") then - at="/lib/"..mn..".lua" - elseif fs.exists(shell.dir().."/lib/"..mn..".lua") then - at=shell.dir().."/lib/"..mn..".lua" - end - if at then - local e=getfenv(1) - if e.package and #e.package.loaders==2 then - table.insert(e.package.loaders,loader) - end - return loadfile(at,nil,e) - end - return false,"\t\tno file '/lib/"..mn..".lua\n\t\tno file '"..shell.dir().."/lib/"..mn..".lua" -end - -local osrun=_G.os.run -function _G.os.run(e,p,...) - if e.package and #e.package.loaders==2 then - table.insert(e.package.loaders,loader) - end - return osrun(e,p,...) -end -shell.setPath(shell.path()..":/bin") diff --git a/binpath/pkgmeta.ltn b/binpath/pkgmeta.ltn new file mode 100644 index 0000000..61de9d5 --- /dev/null +++ b/binpath/pkgmeta.ltn @@ -0,0 +1,12 @@ +{ + ["version"] = "0.1.0", + ["dependencies"] = { + + }, + ["description"] = "Makes shell look in /bin.", + ["files"] = { + ["startup"] = { + "binpath.lua" + } + }, +} diff --git a/binpath/startup/binpath.lua b/binpath/startup/binpath.lua new file mode 100644 index 0000000..caf15af --- /dev/null +++ b/binpath/startup/binpath.lua @@ -0,0 +1 @@ +shell.setPath(shell.path()..":/bin") diff --git a/pkgm/bin/pkgm.lua b/pkgm/bin/pkgm.lua index 4918b61..b36052e 100644 --- a/pkgm/bin/pkgm.lua +++ b/pkgm/bin/pkgm.lua @@ -1,5 +1,5 @@ local args={...} -local pkg=require "pkgm" +local pkg=dofile "/lib/mfs" local flags={} local ptr=#args while ptr>0 do diff --git a/pkgm/lib/pkgm.lua b/pkgm/lib/pkgm.lua index c5634c7..b1e0013 100644 --- a/pkgm/lib/pkgm.lua +++ b/pkgm/lib/pkgm.lua @@ -1,4 +1,4 @@ -local mfs=require "mfs" +local mfs=dofile "/lib/mfs" local local_pkg_files=false local pkg_url="https://git.osmarks.tk/heavpoot/packages1/raw/branch/master/" local res={} diff --git a/pkgm/pkgmeta.ltn b/pkgm/pkgmeta.ltn index 2ed48c6..407d979 100644 --- a/pkgm/pkgmeta.ltn +++ b/pkgm/pkgmeta.ltn @@ -1,8 +1,8 @@ { - ["version"] = "0.1.2-2", + ["version"] = "0.1.2-3", ["dependencies"] = { "mfs", - "add_lib_ppl", + "binpath", }, ["description"] = "Package manager. For managing packages, bee incursions and other apionic systems.", ["files"] = {