LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 10-03-2012, 02:02 PM   #1
Advice Pro
Member
 
Registered: Mar 2009
Location: Virginia, US
Distribution: Ubuntu 10.10 & Debian 6.0.3,
Posts: 343

Rep: Reputation: 7
I can't transcript an install.


To transcript, I type:
Code:
script -a
or
Code:
script filename.txt
To install, I type:
Code:
sudo apt-get install
I just can't get them both to work together
 
Old 10-03-2012, 02:48 PM   #2
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 6,681
Blog Entries: 14

Rep: Reputation: 1022Reputation: 1022Reputation: 1022Reputation: 1022Reputation: 1022Reputation: 1022Reputation: 1022Reputation: 1022
How about:
Code:
script -ac "sudo apt-get install"
The -c tells it to execute the command rather than invoking a subshell. The quotes around the command and its arguments insures that is what the -c acts upon.

Similar syntax works for me on RHEL:
Code:
script -ac "sudo yum list"
I don't have a system using apt-get but it seems it should work there as well as the purpose of both yum and apt-get is package management for their respective distros.
 
Old 10-03-2012, 02:59 PM   #3
Advice Pro
Member
 
Registered: Mar 2009
Location: Virginia, US
Distribution: Ubuntu 10.10 & Debian 6.0.3,
Posts: 343

Original Poster
Rep: Reputation: 7
Thanks, but is there a way to name the file in the command?
 
Old 10-03-2012, 05:19 PM   #4
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 6,681
Blog Entries: 14

Rep: Reputation: 1022Reputation: 1022Reputation: 1022Reputation: 1022Reputation: 1022Reputation: 1022Reputation: 1022Reputation: 1022
Yes - the argument after command is the file name:

Code:
script -ac "sudo apt-get install" filename.txt
 
  


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
[SOLVED] SSH/bash session transcript theillien Linux - Server 2 03-20-2012 10:47 AM
LXer: Transcript: Ciaran O'Riordan on the End Software Patents campaign LXer Syndicated Linux News 0 04-01-2009 01:10 AM
LXer: RMS transcript on GPLv3, Novell/MS, Tivo and more LXer Syndicated Linux News 0 11-27-2006 12:33 PM
LXer: The unabridged selective transcript of Richard M Stallman's talk at the ANU LXer Syndicated Linux News 0 04-06-2006 11:03 PM
LXer: Microsoft's Yates' to MA: How About 2 Standards? - Transcript LXer Syndicated Linux News 0 12-16-2005 08:46 AM


All times are GMT -5. The time now is 01:03 PM.

Main Menu
Advertisement
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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration