]> git.e2factory.org Git - e2factory.git/commitdiff
Remove E2_LOCAL_TAG and E2_LOCAL_BRANCH environment variables
authorTobias Ulmer <tu@emlix.com>
Fri, 27 Sep 2013 16:41:32 +0000 (18:41 +0200)
committerTobias Ulmer <tu@emlix.com>
Wed, 16 Nov 2016 14:01:23 +0000 (15:01 +0100)
Looks like these were initially used for automated tests.  The same
settings can now be made in e2.conf.

Nothing that I know of has known or used these environment variables, so
I consider it OK to "break" backwards compat.

Signed-off-by: Tobias Ulmer <tu@emlix.com>
doc/man/e2-create-project.1.in
generic/e2lib.lua
global/e2-create-project.lua

index 6c44531f2ff472f34ffb5a8b48561fc777b0dc31..34c7a0dec46ce075fe56a30f2b5662b8b1a3e1cb 100644 (file)
@@ -32,16 +32,6 @@ Create a new project:
 e2-create-project foo/bar
 .fi
 
-.SH ENVIRONMENT
-Following environment variables are evaluated:
-.TP
-.BR E2_LOCAL_BRANCH
-Branch of version of e2factory to be used.
-.TP
-.BR E2_LOCAL_TAG
-Tag of version of e2factory to be used.
-
-
 .SH SEE ALSO
 .BR e2factory(1)
 
index 9a616efce97a97d8e54afb6924bc0e48beb259f5..127f3650123187df9ccf691f6feb81de9c209943 100644 (file)
@@ -86,8 +86,6 @@ e2lib.globals = {
     tmpfiles = {},
     default_projects_server = "projects",
     default_project_version = "2",
-    local_e2_branch = nil,
-    local_e2_tag = nil,
     --- command line arguments that influence global settings are stored here
     -- @class table
     -- @name cmdline
@@ -376,8 +374,6 @@ function e2lib.init()
         { name = "E2TMPDIR", required = false },
         { name = "COLUMNS", required = false, default = "72" },
         { name = "E2_SSH", required = false },
-        { name = "E2_LOCAL_BRANCH", required = false },
-        { name = "E2_LOCAL_TAG", required = false },
     }
 
     local osenv = {}
index 6487b1c551814bfda25f7531def2a50e51b55f6c..4667e56b67f2fa5a3e5b1ad9ded0ac17caebd290 100644 (file)
@@ -67,36 +67,20 @@ local function e2_create_project(arg)
         return false, e:cat(re)
     end
 
-    -- standard global tool setup finished
-
-    if e2lib.globals.osenv["E2_LOCAL_TAG"] and e2lib.globals.osenv["E2_LOCAL_BRANCH"] then
-        e2lib.globals.local_e2_branch = e2lib.globals.osenv["E2_LOCAL_BRANCH"]
-        e2lib.globals.local_e2_tag = e2lib.globals.osenv["E2_LOCAL_TAG"]
-    elseif e2lib.globals.osenv["E2_LOCAL_TAG"] then
-        e2lib.globals.local_e2_branch = "-"
-        e2lib.globals.local_e2_tag = e2lib.globals.osenv["E2_LOCAL_TAG"]
-    elseif e2lib.globals.osenv["E2_LOCAL_BRANCH"] then
-        e2lib.globals.local_e2_branch = e2lib.globals.osenv["E2_LOCAL_BRANCH"]
-        e2lib.globals.local_e2_tag = "^"
-    else
-        e2lib.globals.local_e2_branch = config.site.e2_branch
-        e2lib.globals.local_e2_tag =  config.site.e2_tag
-    end
-
     if #arguments ~= 1 then
         e2option.usage(1)
     end
 
     local sl, re = e2lib.parse_server_location(arguments[1],
-    e2lib.globals.default_projects_server)
+        e2lib.globals.default_projects_server)
     if not sl then
         return false, e:cat(re)
     end
 
     local p = {}
     p.version = buildconfig.GLOBAL_INTERFACE_VERSION[1] -- the project version
-    p.e2version = string.format("%s %s", e2lib.globals.local_e2_branch,
-    e2lib.globals.local_e2_tag)
+    p.e2version = string.format("%s %s",
+        config.site.e2_branch, config.site.e2_tag)
     p.server = sl.server                               -- the server
     p.location = sl.location                   -- the project location
     p.name = e2lib.basename(sl.location)               -- the project basename