Modify

Opened 9 years ago

Closed 9 years ago

#56 closed enhancement (fixed)

Second stage install instructions multiline execute

Reported by: Geert Stappers <stappers@…> Owned by: stappers
Priority: minor Milestone: milestone:
Component: debian/packages Version: 2.0
Severity: Keywords:
Cc:

Description

Hello,

Second stage install instructions are printed from /etc/init.d/rcS.firstboot. When the first is executed ( debootstrap --second-stage are the
instructions scrolled from the screen, and so lost for the user.

Yes, that is as told by amain at the Roosendaal Local Linux User Group.

Attachments (0)

Change History (6)

comment:1 Changed 9 years ago by Geert Stappers <stappers@…>

You to copy and paste, copy all the instructions and paste them:

Second stage install instructions:

  /debootstrap/debootstrap --second-stage  ;
  rm -rf /var/cache/apt/archives  ;
  mkdir -p /var/cache/apt/archives/partial  ;
  echo "deb http://ftp.debian.org/debian squeeze main" >>/etc/apt/sources.list
# OR
- echo "deb http://ftp.debian.org/debian sid main" >>/etc/apt/sources.list
- for Lenny: dpkg-reconfigure dash

 Don't execute these lines, these are a reminder for myself(amain) when preparing an DebWrt release:
- rm -rf /lib/modules/*
- rm -rf /lib/firmware/*

root@debwrt:/#   /debootstrap/debootstrap --second-stage  ;
  rm -rf /var/cache/apt/archives  ;
  mkdir -p /var/cache/apt/archives/partial  ;
  echo "deb http://ftp.debian.org/debian squeeze main" >>/etc/apt/sources.list
# OR
I: Installing core packages...

( I hope that one can see what was cut 'n pasted )

comment:2 Changed 9 years ago by Geert Stappers <stappers@…>

This patch makes it possible:

--- debian/rootfs/files/etc/init.d/rcS.firstboot        (revision 140)
+++ debian/rootfs/files/etc/init.d/rcS.firstboot        (working copy)
@@ -34,11 +34,11 @@
 /bin/echo
 /bin/echo "Second stage install instructions:"
 /bin/echo
-/bin/echo "- /debootstrap/debootstrap --second-stage"
-/bin/echo "- rm -rf /var/cache/apt/archives"
-/bin/echo "- mkdir -p /var/cache/apt/archives/partial"
-/bin/echo "- echo \"deb http://ftp.debian.org/debian squeeze main\" >>/etc/apt/sources.list"
-/bin/echo "  OR"
+/bin/echo "  /debootstrap/debootstrap --second-stage  ;"
+/bin/echo "  rm -rf /var/cache/apt/archives  ;"
+/bin/echo "  mkdir -p /var/cache/apt/archives/partial  ;"
+/bin/echo "  echo \"deb http://ftp.debian.org/debian squeeze main\" >>/etc/apt/sources.list"
+/bin/echo "# OR"
 /bin/echo "- echo \"deb http://ftp.debian.org/debian sid main\" >>/etc/apt/sources.list"
 /bin/echo "- for Lenny: dpkg-reconfigure dash"
 /bin/echo

The trick is the semicolon, it makes multiple logical lines on one physical line possible.

comment:3 Changed 9 years ago by amain

  • Owner changed from amain to stappers@…
  • Status changed from new to assigned

Geert, feel free to make any changes here.

Personally I would say:

  • indeed use the semi-column to concatenate statements on one bash line
  • scroll back
  • cat /etc/init.d/rc.firstboot to see instructions again

Assigning to you...it would be nice to have a more user friendly way of presenting this. But I don't want any extra files lingering around on the debwrt rootfs. Want to keep it as clean as possible. Ideally: every file on the rootfs should be part of a .deb package.

comment:4 Changed 9 years ago by stappers

commited as r157

comment:5 Changed 9 years ago by stappers

  • Owner changed from stappers@… to stappers
  • Status changed from assigned to accepted

comment:6 Changed 9 years ago by amain

  • Resolution set to fixed
  • Status changed from accepted to closed

Patch looks good. Closing bug.

Add Comment

Modify Ticket

Action
as closed The owner will remain stappers.
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.