SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I am new to Slackware this year and want to start sharing my experiences setting up slackware. I usually solve my own problems by reading your wonderful posts here. Unfortunately by the time I am done altering config files and entering cli commands I don't remember all the steps I did to fix the problem. I was wondering is there an easy way to record my terminal sessions. I have read about using script but it says it wont work if I use VIM. Is there a way I can record the terminal that will also record the changes I make in vim as well, or maybe use another cli editor that script can record?
Thanks
BTW: I have to say besides slackware being a great distro this community has mad my transition to slack a great experience.
Someone else may offer a suggestion more automated. Every time I've thought that this was what I wanted, it turned out that it was more difficulty to me versus using the two methods I am going to suggest. First, the history(3) command will print out your most recent commands up to a certain limit and I believe you can play with a property to see more than the default. The default is pretty large though. The second suggestion is to realize that you're doing stuff which you'll want to remember and repeat; so keep a log via other means.
What I do is I keep open a document, or a draft email and cut/paste my progress in there. Also this is more useful to me because there are things which aren't commands entered which you will want to retain. For instance if there is a setup file which I need to edit and add some lines, and say I did a vi session of a file. The fact that I did the vi shows in my history, however the changes I made will not; so I copy/paste the relevant file chunks into the log that I keep. Furthermore, if I searched the web for a solution and found a great resource, I copy that hyperlink into my log.
I actually do this a lot because I configure and bring up many prototype boards, build a bootloader and kernel for them and have to configure the kernel and bootloader for our intended applications. As a result it's days of experimentation and customization, a lot of the work may be failed experimentation where I will not care to retain my failed efforts, but the really difficult to attain issues definitely require me to keep a detailed log of actions, attempts, and results so that I can repeat and devise better methods for the next iteration.
So, to me it's more than just an organized history of command I've entered, it's instead the extra information which came from that whole picture.
The second suggestion is to realize that you're doing stuff which you'll want to remember and repeat; so keep a log via other means.
The points made in that post are excellent. Just to let you know that rtmistler isn't alone. I've also found that "...keep a log via other means." has worked best for me.
I simply keep a written log, similar to a laboratory notebook which I record the sequential steps of my "experiment" and add notes and references such as WHY something worked or didn't work. When I occasionally have a success I separately summarize the steps to that success.
This out-of-band method could be done by typing into a second computer rather than handwritten for those, like the OP, who want to share their activities.
In some environments the logging computer can be connected to the target computer as a console to facilitate copy/paste functions. I mention this because much of the time the issue involved is the boot sequence when the target machine has limited resources available for recording/typing/editing. But I imagine it's rare to find an environment these days where one can connect a logging console up via the serial port. (showing my age)
Quote:
Originally Posted by rtmistler
So, to me it's more than just an organized history of command I've entered, it's instead the extra information which came from that whole picture.
I found another advantage to "writing/typing" rather than simply "recording" is similar to why one designs a program rather than to just start coding. The process encourages one to think about the process rather than just trial-and-error.
I also keep text file notes, have been doing that for a long time, and keep them all in one directory in my /home/~. I also make up one liner scripts for very long commands that I will use again and keep them in /usr/local/bin. That way I can refer to them or use them using just a one word command in a terminal.
The following advice reminds me of a joke, but here goes...
Never do anything that cannot be accomplished by a shell script. (Or perl script or python script or ruby script or awk script....)
Instead of doing the thing directly, you write the script that does the action. Save the script. There's your record.
Oh yeah, it's this joke:
Quote:
There was a pilot coming into the Seattle airport through thick fog when his instruments went out.
He was circling around and he saw a tall building with a guy working alone on the top floor. He cut the engine and rolled down the window and yelled, "Hey where am I?"
The man said, "You're in an airplane." The pilot made a 275 degree turn and brought the plane in for a perfect landing on the runway 5 miles away just as the fuel has run out. The passengers were amazed and asked how he did it.
The pilot said, "It was easy. I asked the guy in that building a simple question. The answer he gave me was 100 percent correct an absolutely useless, therefore, that must be Microsoft's support office and from there the airport is five miles due East."
Thanks for all the replies guys....(like the joke Richard)
Ill probably end up using more then one of the solutions suggested, depending on what I am setting up at the time. Ill mark the link as solved, but if anyone else would like to share, please do..
Last edited by linuxtinker; 04-19-2014 at 09:39 AM.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.