Merge ~mwhudson/curtin:swap-exit into curtin:master

Proposed by Michael Hudson-Doyle
Status: Merged
Approved by: Dan Bungert
Approved revision: 9ccf75c478e96802da41c2e4392c093bff7e2474
Merge reported by: Server Team CI bot
Merged at revision: not available
Proposed branch: ~mwhudson/curtin:swap-exit
Merge into: curtin:master
Diff against target: 13 lines (+1/-1)
1 file modified
curtin/commands/swap.py (+1/-1)
Reviewer Review Type Date Requested Status
Dan Bungert Approve
Server Team CI bot continuous-integration Approve
Review via email: mp+433683@code.launchpad.net

Commit message

fix "curtin swap" exit code

Today I discovered that there is a "curtin swap" command that just does
the "configure swap" part of curthooks and then I fairly quickly after
that discovered that probably noone has used it because it
unconditionally exits with code 2 even if everything succeeded.

To post a comment you must log in.
Revision history for this message
Server Team CI bot (server-team-bot) wrote :
review: Approve (continuous-integration)
Revision history for this message
Dan Bungert (dbungert) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/curtin/commands/swap.py b/curtin/commands/swap.py
2index 089cd73..a5082ac 100644
3--- a/curtin/commands/swap.py
4+++ b/curtin/commands/swap.py
5@@ -41,7 +41,7 @@ def swap_main(args):
6 swap.setup_swapfile(target=state['target'], fstab=state['fstab'],
7 swapfile=args.swapfile, size=size,
8 maxsize=args.maxsize, force=args.force)
9- sys.exit(2)
10+ sys.exit(0)
11
12
13 CMD_ARGUMENTS = (

Subscribers

People subscribed via source and target branches