LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
Search this Thread
Old 11-07-2013, 04:01 AM   #1
Phorize
Member
 
Registered: Sep 2005
Location: UK
Distribution: Slackware
Posts: 218

Rep: Reputation: 26
Direct output of mkinitrd command generator to shell


Hi All,

Is there a way of directing/piping the output of mkinitrd_command_generator.sh directly to the shell so that I don't need to type out the resultant command?
 
Old 11-07-2013, 04:17 AM   #2
Didier Spaier
Senior Member
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slackware{,64}-{14.1,current} on a Lenovo Thinkpad T61 6457-4XG
Posts: 4,380

Rep: Reputation: 1088Reputation: 1088Reputation: 1088Reputation: 1088Reputation: 1088Reputation: 1088Reputation: 1088Reputation: 1088
Just pipe it to bash
 
Old 11-07-2013, 04:17 AM   #3
bormant
Member
 
Registered: Jan 2008
Posts: 100

Rep: Reputation: 47
Use pipe to bash:
# /usr/share/mkinitrd/mkinitrd_command_generator.sh parameters_if_needed | bash
 
Old 11-07-2013, 04:50 AM   #4
wadsworth
Member
 
Registered: Aug 2007
Distribution: Slackware64 13.37
Posts: 215

Rep: Reputation: 64
Or put the command inside "$( )" like so:
Code:
$(/usr/share/mkinitrd/mkinitrd_command_generator.sh -r)
 
Old 11-07-2013, 04:59 AM   #5
kikinovak
Senior Member
 
Registered: Jun 2011
Location: Montpezat (South France)
Distribution: Slackware, Slackware64
Posts: 1,725

Rep: Reputation: 830Reputation: 830Reputation: 830Reputation: 830Reputation: 830Reputation: 830Reputation: 830
I always open /etc/mkinitrd.conf with Vim, paste the output of mkinitrd_command_generator.sh into the configuration file (:r !/usr/share/mkinitrd/mkinitrd_command_generator.sh) and then edit it.
 
Old 11-07-2013, 06:09 AM   #6
allend
Senior Member
 
Registered: Oct 2003
Location: Melbourne
Distribution: Slackware-current
Posts: 3,462

Rep: Reputation: 852Reputation: 852Reputation: 852Reputation: 852Reputation: 852Reputation: 852Reputation: 852
Highlight the output with the left mouse button held down, then paste with the middle button. Maybe uncool and uncouth, but works for me.
 
1 members found this post helpful.
Old 11-07-2013, 06:14 AM   #7
01micko
Member
 
Registered: Mar 2009
Location: Gold Coast, Queensland, Australia
Distribution: Puppy, Slackware
Posts: 79

Rep: Reputation: 7
Quote:
Originally Posted by allend View Post
Highlight the output with the left mouse button held down, then paste with the middle button. Maybe uncool and uncouth, but works for me.
+1 (must be an Australian thing )
 
Old 11-07-2013, 03:27 PM   #8
perbh
Member
 
Registered: May 2008
Location: Republic of Texas
Posts: 258

Rep: Reputation: 39
Quote:
Originally Posted by 01micko View Post
+1 (must be an Australian thing )
long live the lazy!! (ie, I do exactly the same)
 
Old 11-07-2013, 03:39 PM   #9
Daedra
Senior Member
 
Registered: Dec 2005
Location: Springfield, MO
Distribution: Slackware64-14.1
Posts: 1,223

Rep: Reputation: 177Reputation: 177
Quote:
Originally Posted by allend View Post
Highlight the output with the left mouse button held down, then paste with the middle button. Maybe uncool and uncouth, but works for me.
+2, 60% of the time, it works Everytime!
 
Old 11-07-2013, 09:26 PM   #10
XGizzmo
Member
 
Registered: Mar 2007
Distribution: Slackware
Posts: 264

Rep: Reputation: 68
# $(/usr/share/mkinitrd/mkinitrd_command_generator.sh) FTW
 
Old 11-08-2013, 05:34 AM   #11
ellington
LQ Newbie
 
Registered: May 2012
Location: Brazil
Distribution: Slackware Linux
Posts: 6

Rep: Reputation: Disabled
# /usr/share/mkinitrd/mkinitrd_command_generator.sh -c > /etc/mkinitrd.conf
# mkinitrd -F

So you can keep track of your configs.
 
1 members found this post helpful.
Old 11-08-2013, 07:19 AM   #12
brianL
LQ 5k Club
 
Registered: Jan 2006
Location: Oldham, Lancs, England
Distribution: Slackware & Slackware64 14.1
Posts: 7,040
Blog Entries: 52

Rep: Reputation: Disabled
Quote:
Originally Posted by allend View Post
Highlight the output with the left mouse button held down, then paste with the middle button. Maybe uncool and uncouth, but works for me.
Same here.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Using shell command output as input in shell script - how to do? EnderX Linux - Newbie 2 06-30-2010 12:46 PM
[SOLVED] initrd and generic kernel fails to boot with errors after using mkinitrd generator adamschock Slackware 8 06-26-2010 02:30 PM
[SOLVED] How to direct standard output from find command dyq Programming 3 03-26-2010 03:55 PM
sudo mkinitrd -o /boot/initrd.img-2.6.32.9 2.6.32.9 sudo: mkinitrd: command not foun vishwas181 Linux - Newbie 1 02-27-2010 01:16 AM
shell command without output ricardo85xeii Programming 2 10-17-2007 11:58 AM


All times are GMT -5. The time now is 04:01 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration