← Back to team overview

curtin-dev team mailing list archive

[Merge] ~dbungert/curtin:generate-main into curtin:master

 

Dan Bungert has proposed merging ~dbungert/curtin:generate-main into curtin:master.

Commit message:
bin/curtin: update generator for recent changes
    
bin/curtin is a generated file, but has been edited directly recently.
Update the generator tools to match recent changes.


Requested reviews:
  curtin developers (curtin-dev)

For more details, see:
https://code.launchpad.net/~dbungert/curtin/+git/curtin/+merge/406835
-- 
Your team curtin developers is requested to review the proposed merge of ~dbungert/curtin:generate-main into curtin:master.
diff --git a/Makefile b/Makefile
index 187132c..bb8576b 100644
--- a/Makefile
+++ b/Makefile
@@ -2,6 +2,7 @@ TOP := $(abspath $(dir $(lastword $(MAKEFILE_LIST))))
 CWD := $(shell pwd)
 PYTHON2 ?= python2
 PYTHON3 ?= python3
+PYTHON ?= $(PYTHON3)
 COVERAGE ?= 1
 DEFAULT_COVERAGEOPTS = --with-coverage --cover-erase --cover-branches --cover-package=curtin --cover-inclusive 
 ifeq ($(COVERAGE), 1)
diff --git a/bin/curtin b/bin/curtin
index 89cb319..2f7b5f5 100755
--- a/bin/curtin
+++ b/bin/curtin
@@ -55,5 +55,3 @@ if [ ! -n "$PYTHON" ]; then
 fi
 debug "executing: $PYTHON -m \"$PY3OR2_MAIN\" $*"
 exec $PYTHON -m "$PY3OR2_MAIN" "$@"
-
-# vi: ts=4 expandtab syntax=sh
diff --git a/curtin/pack.py b/curtin/pack.py
index 1dd42fb..e3f76e1 100644
--- a/curtin/pack.py
+++ b/curtin/pack.py
@@ -10,10 +10,12 @@ from . import version
 
 CALL_ENTRY_POINT_SH_HEADER = """
 #!/bin/sh
+# This file is part of curtin. See LICENSE file for copyright and license info.
+
 PY3OR2_MAIN="%(ep_main)s"
 PY3OR2_MCHECK="%(ep_mcheck)s"
 PY3OR2_PYTHONS=${PY3OR2_PYTHONS:-"%(python_exe_list)s"}
-PYTHON=${PY3OR2_PYTHON}
+PYTHON=${PYTHON:-"$PY3OR2_PYTHON"}
 PY3OR2_DEBUG=${PY3OR2_DEBUG:-0}
 """.strip()
 
diff --git a/tools/write-curtin b/tools/write-curtin
index eb1399d..88fd604 100755
--- a/tools/write-curtin
+++ b/tools/write-curtin
@@ -16,7 +16,7 @@ if path == "-":
 else:
     parg = path
 
-ret = write_exe_wrapper(entrypoint="curtin.commands.main", path=parg,
+ret = write_exe_wrapper(entrypoint="curtin", path=parg,
                         deps_check_entry="curtin.deps.check")
 
 if path == "-":

Follow ups