Gentoo Archives: gentoo-catalyst

From: Mike Frysinger <vapier@g.o>
To: gentoo-catalyst@l.g.o
Subject: [gentoo-catalyst] [PATCH 03/13] lint: fix bad indentation
Date: Tue, 06 Oct 2015 15:05:47
Message-Id: 1444143929-26705-3-git-send-email-vapier@gentoo.org
In Reply to: [gentoo-catalyst] [PATCH 01/13] lint: fix duplicate fcntl import by Mike Frysinger
1 Fix code that has excessive indentation relative to previous levels.
2 ---
3 catalyst/arch/x86.py | 4 ++--
4 catalyst/base/stagebase.py | 6 +++---
5 catalyst/targets/livecd_stage1.py | 2 +-
6 catalyst/targets/livecd_stage2.py | 2 +-
7 catalyst/targets/netboot2.py | 4 ++--
8 catalyst/targets/stage2.py | 12 ++++++------
9 6 files changed, 15 insertions(+), 15 deletions(-)
10
11 diff --git a/catalyst/arch/x86.py b/catalyst/arch/x86.py
12 index 49500b9..33b29c0 100644
13 --- a/catalyst/arch/x86.py
14 +++ b/catalyst/arch/x86.py
15 @@ -10,8 +10,8 @@ class generic_x86(builder.generic):
16 builder.generic.__init__(self,myspec)
17 if self.settings["buildarch"]=="amd64":
18 if not os.path.exists("/bin/linux32") and not os.path.exists("/usr/bin/linux32"):
19 - raise CatalystError("required executable linux32 not found "
20 - "(\"emerge setarch\" to fix.)", print_traceback=True)
21 + raise CatalystError("required executable linux32 not found "
22 + "(\"emerge setarch\" to fix.)", print_traceback=True)
23 self.settings["CHROOT"]="linux32 chroot"
24 self.settings["crosscompile"] = False
25 else:
26 diff --git a/catalyst/base/stagebase.py b/catalyst/base/stagebase.py
27 index a9e7848..b9dd1d5 100644
28 --- a/catalyst/base/stagebase.py
29 +++ b/catalyst/base/stagebase.py
30 @@ -853,9 +853,9 @@ class StageBase(TargetBase, ClearBase, GenBase):
31 and os.path.exists(target_portdir) \
32 and self.resume.is_enabled("unpack_portage") \
33 and self.settings["snapshot_path_hash"] == snapshot_hash:
34 - print \
35 - "Valid Resume point detected, skipping unpack of portage tree..."
36 - unpack=False
37 + print \
38 + "Valid Resume point detected, skipping unpack of portage tree..."
39 + unpack = False
40
41 if unpack:
42 if "snapcache" in self.settings["options"]:
43 diff --git a/catalyst/targets/livecd_stage1.py b/catalyst/targets/livecd_stage1.py
44 index ff320c0..262db70 100644
45 --- a/catalyst/targets/livecd_stage1.py
46 +++ b/catalyst/targets/livecd_stage1.py
47 @@ -34,7 +34,7 @@ class livecd_stage1(StageBase):
48 self.settings["target_path"]=normpath(self.settings["storedir"]+"/builds/"+self.settings["target_subpath"])
49 if "autoresume" in self.settings["options"] \
50 and self.resume.is_enabled("setup_target_path"):
51 - print "Resume point detected, skipping target path setup operation..."
52 + print "Resume point detected, skipping target path setup operation..."
53 else:
54 # first clean up any existing target stuff
55 if os.path.exists(self.settings["target_path"]):
56 diff --git a/catalyst/targets/livecd_stage2.py b/catalyst/targets/livecd_stage2.py
57 index 870dcf9..b54f2f0 100644
58 --- a/catalyst/targets/livecd_stage2.py
59 +++ b/catalyst/targets/livecd_stage2.py
60 @@ -55,7 +55,7 @@ class livecd_stage2(StageBase):
61 self.settings["target_path"]=normpath(self.settings["storedir"]+"/builds/"+self.settings["target_subpath"])
62 if "autoresume" in self.settings["options"] \
63 and self.resume.is_enabled("setup_target_path"):
64 - print "Resume point detected, skipping target path setup operation..."
65 + print "Resume point detected, skipping target path setup operation..."
66 else:
67 # first clean up any existing target stuff
68 if os.path.isdir(self.settings["target_path"]):
69 diff --git a/catalyst/targets/netboot2.py b/catalyst/targets/netboot2.py
70 index e509cf9..f2d039c 100644
71 --- a/catalyst/targets/netboot2.py
72 +++ b/catalyst/targets/netboot2.py
73 @@ -54,7 +54,7 @@ class netboot2(StageBase):
74 self.settings["target_subpath"])
75 if "autoresume" in self.settings["options"] \
76 and self.resume.is_enabled("setup_target_path"):
77 - print "Resume point detected, skipping target path setup operation..."
78 + print "Resume point detected, skipping target path setup operation..."
79 else:
80 # first clean up any existing target stuff
81 if os.path.isfile(self.settings["target_path"]):
82 @@ -70,7 +70,7 @@ class netboot2(StageBase):
83 # check for autoresume point
84 if "autoresume" in self.settings["options"] \
85 and self.resume.is_enabled("copy_files_to_image"):
86 - print "Resume point detected, skipping target path setup operation..."
87 + print "Resume point detected, skipping target path setup operation..."
88 else:
89 if "netboot2/packages" in self.settings:
90 if type(self.settings["netboot2/packages"]) == types.StringType:
91 diff --git a/catalyst/targets/stage2.py b/catalyst/targets/stage2.py
92 index 40dc938..affa2cb 100644
93 --- a/catalyst/targets/stage2.py
94 +++ b/catalyst/targets/stage2.py
95 @@ -56,9 +56,9 @@ class stage2(StageBase):
96 self.settings["LDFLAGS"]=list_to_string(self.settings["ldflags"])
97
98 def set_portage_overlay(self):
99 - StageBase.set_portage_overlay(self)
100 - if "portage_overlay" in self.settings:
101 - print "\nWARNING !!!!!"
102 - print "\tUsing an portage overlay for earlier stages could cause build issues."
103 - print "\tIf you break it, you buy it. Don't complain to us about it."
104 - print "\tDont say we did not warn you\n"
105 + StageBase.set_portage_overlay(self)
106 + if "portage_overlay" in self.settings:
107 + print "\nWARNING !!!!!"
108 + print "\tUsing an portage overlay for earlier stages could cause build issues."
109 + print "\tIf you break it, you buy it. Don't complain to us about it."
110 + print "\tDont say we did not warn you\n"
111 --
112 2.5.2