Sponsored Content
Top Forums Shell Programming and Scripting [ksh] how to reload history file without entering a command Post 303027900 by Neo on Thursday 27th of December 2018 11:34:59 PM
Old 12-28-2018
Quote:
Originally Posted by jim mcnamara
... If the shell you use will not get updated like bash does, this can be one way to get custom behaviors.
Alternatively, if you can read C, consider spending some time read the source code for ksh93 if that is your shell. The code is now on github. ....
This is immensely important for technical people who are pushing the envelope or working on custom behaviors.

It's always best to go to the source code, when available, to understand what is going on under-the-hood and to add custom code.

Arguably, reading C or C++ code is a lot more difficult than reading PHP or Javascript or Python or C#, etc. at least for me, I find C or C++ is too down-in-the-weeds to easily grasp the functionality of the code.

I spend a lot of time coding, I mean a LOT Of time coding, and at least for me, writing code is a kind of digital artistic poetry, where bug hunting makes me smile and odd behavioral issues turn me into a kind of Sherlock Holmes for code.

Side story:

I was in truck riding along in the mountains with a US-born web developer turned real-estate agent recently. We were talking about coding and he told me he often slams the keyboard down or yells at his computer when coding and doing IT. He looked at me for affirmation of his frustration. I told in in reply that I mostly get joy from IT and coding, and often find myself smiling when bug hunting and when things do not go as expected. In fact, I told him that I find it hard to have any emotions when coding and problem solving, except for joy, and when I wake up in the morning, I am really excited to have that cup of java and login and code solutions my mind figured out when I was asleep.

Sometimes even here, I see people getting emotional over something (recently a moderator threatened to quit because they don't like some of my code changes and the transitions I am working on here). I am surprised by this and this has led to be believe I've been working in IT for so long, that writing code brings me truly great joy. Negative emotions are not really useful and so I don't have them over anything. However, I see a lot of IT people carry around with them a lot of frustration and anger and emotions related to IT and technology (mostly the middle aged and much older IT people, not the younger generation).

Anyway, I'm well off topic.

My point is that IT is a joy, coding is not some "geeky thing for losers" but it is a blessing and a great way to use your mind. Jim was right on to suggest looking at the ksh source for DevuanFan's custom ideas; and I hope DevuanFan will read the source and post back the code, the details he learned and his proposed solution

If you are in IT and do not love to code, search code, read code, write code, you are in the wrong business or hobby!
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

entering a long command

hello everyone! Very basic question for the guru's in here but anyways, I am trying to type a command that is longer than the line. What character do I use to continue my command on the next line? Thanks in advance.... Todd (1 Reply)
Discussion started by: hedrict
1 Replies

2. UNIX for Dummies Questions & Answers

ksh: how to make [up arrow] recall command history

I want to get my up arrow key to recall my previous commands in Korn shell. Anyone help please? thanks a bunch! BG (3 Replies)
Discussion started by: BG_JrAdmin
3 Replies

3. UNIX for Dummies Questions & Answers

Reload user crontab file

Hi Guys, Our user crontab files are located at /var/spool/cron/crontabs. I have to make some modifications to it. I have all the crontab entries in a file called 'crontab.actual'. I made changes to this file and now I want to reload these changes from the crontab.actual file to my crontab... (12 Replies)
Discussion started by: vandi
12 Replies

4. Solaris

Command for checking modification history on file

What is the command for checking modification history on file? ---------- Post updated at 01:20 PM ---------- Previous update was at 12:35 PM ---------- Let me rephrase this. On a regular Unix file can I at least check to see the time and date history modification of the file? (6 Replies)
Discussion started by: jastanle84
6 Replies

5. Shell Programming and Scripting

What is the ksh equivalent to bash's "history -c" command?

Hi, What is the korn shell equivalent of bash shell's "history -c" command? I do know, how to clear the history list in ksh, I can do the following: > ~/.sh_historybut still, I am interested to know the single one line command as 'history -c' gives error on my ksh (1 Reply)
Discussion started by: royalibrahim
1 Replies

6. Solaris

Login delay after entering id (40 secs) same after entering pw

Hi all, I have just installed Solaris 10 on an old Fujitsu Primepower 650 which has been wiped clean. I haven't installed anything apart from the OS yet, so the machine is 99% idle. I get long delays when logging in, first after entering the id then another long delay after entering a valid... (8 Replies)
Discussion started by: longjon
8 Replies

7. UNIX for Dummies Questions & Answers

Command to reload a zone

I just created a CNAME and i was told a zone needs to be reloaded after creating a CNAME. What is the command to reload a zone after the CNAME has been created? Thanks in advance (1 Reply)
Discussion started by: German Shepherd
1 Replies

8. Shell Programming and Scripting

UNIX CO command for file version history

Hello :) I'm a newb when it comes to shell scripting and was wondering about a command(s) for a script that could be used to checkout a certain number of version/revision histories of a file. I know for the latest revison you "co filename" or for a certain revision number "co -r*.* filename"... (2 Replies)
Discussion started by: MN-DBA
2 Replies

9. AIX

Checking the command history file in AIX

Hello, The system has been rebooted and I need to see the commands executed in the system prior to restart by the oracle user.The history command is not showing me the commands executed prior to reboot. Please advise. Best regards, Vishal (1 Reply)
Discussion started by: Vishal_dba
1 Replies

10. Shell Programming and Scripting

Script not entering VRFY after nc command

I am making a bash script right now and am running into an issue. As I am new to scripting, I do not know exactly what to do to get what I'm looking for in my script. Essentially, my script will automatically input VRFY common names after nc Example: nc 192.168.248.133 25 VRFY Allison... (2 Replies)
Discussion started by: ksrhayward
2 Replies
MANCONV(1)							Manual pager utils							MANCONV(1)

NAME
manconv - convert manual page from one encoding to another SYNOPSIS
manconv -f from-code[:from-code...] -t to-code [-dqhV] [filename] DESCRIPTION
manconv converts a manual page from one encoding to another, like iconv. Unlike iconv, it can try multiple possible input encodings in sequence. This is useful for manual pages installed in directories without an explicit encoding declaration, since they may be in UTF-8 or in a legacy character set. If an encoding declaration is found on the first line of the manual page, that declaration overrides any input encodings specified on man- conv's command line. Encoding declarations have the following form: '" -*- coding: UTF-8 -*- or (if manual page preprocessors are also to be declared): '" t -*- coding: ISO-8859-1 -*- OPTIONS
-f encodings, --from-code encodings Try each of encodings (a colon-separated list) in sequence as the input encoding. -t encoding, --to-code encoding Convert the manual page to encoding. -q, --quiet Do not issue error messages when the page cannot be converted. -d, --debug Print debugging information. -h, --help Print a help message and exit. -V, --version Display version information. SEE ALSO
iconv(1), man(1) AUTHOR
Colin Watson (cjwatson@debian.org). 2.8.3 2018-04-05 MANCONV(1)
All times are GMT -4. The time now is 04:56 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy