Try using backspace instead of the left cursor key.
When I run it on Cygwin, it does not crash. However, it does not process correctly due to the codes generated by the left cursor key and I get the following:
Hello,
Im using cygwin app which we use the bash shell for scripting.
Im trying to read a filename with consecutive spaces on the filename
ex: filename<space><space>1.txt
ls -lrt filename<space><space>1.txt is working but when I pull that from a file and place it into variable. it reads... (1 Reply)
Hi ,
I am currently using the while loop in bash shell, as follows.
while read line
do
echo $line
done < file.txt
However, i want to use the while loop on file.txt, which will read the file with 4 lines of gap.
Ex- if file.txt is a file of 100 lines, then i want to use the loop such... (3 Replies)
Hi,
root@server] df -h
121G 14G 101G 12% /home
147G 126G 14G 91% /backup
We having our site files and images are storing in
/backup/home/user/files/ through symbolic link created in /home directory pointing in /backup directory as following.
root@server] cd /home... (1 Reply)
Hello everyone,
I am struggling a bit with a batch script that I need to run in cygwin. I work in winXP and I had to write some awk scripts to do some file manipulation, and now I would like to automate the process by just running a batch file so that my colleagues can use it easily.
Now, the... (2 Replies)
Hello!
Sorry, for my not so perfect english!
I want to stop bash shell script execution until any key is pressed.
This line in a bash shell script
read -n1 -r -p "Press any key to continue..." key
produces this error
When I run this from the command line
usera@lynx:~$ read... (4 Replies)
I'm writing a bash script that reads a file location from a user, and I'm wondering how to get the script to accept tab to auto complete the directories that are input. (8 Replies)
I'm putting together a script that will search my mail archives for emails that meet certain criteria and output the files to a text file.
I can manually cat that text file and pipe it into sendmail and it will work (i.e. cat /pathtofile/foo.txt | sendmail -t me@company.com)
My script sends... (7 Replies)
I am very new to all these programming languages and really love Linux but have only begun to dive into bash scripting... I am curious what's going on with this script...
#!/bin/bash
if ; then
# xen
grep control_d /proc/xen/capabilities >& /dev/null
if ; then
# domU -- do not run on... (2 Replies)
So I'm trying to pass certain json elements as env vars and use them later on in a script.
Sample json:
JSON='{
"Element1": "file-123456",
"Element2": "Name, of, company written in, a very weird way",
"Element3": "path/to/some/file.txt",
}'
(part of the) script:
for s... (5 Replies)
In Bash shell - the ps -ef shows only the /bin/bash but the script name is not displayed ? Is there any way to get the script names for the process command ?
--- Post updated at 08:39 AM ---
in KSH (Korn Shell), my command output shows the script names but when run in the Bash Shell... (3 Replies)
Discussion started by: i4ismail
3 Replies
LEARN ABOUT ULTRIX
view
view(1) General Commands Manual view(1)Name
view - displays a file using the vi commands
Syntax
view [-t tag] [-r] [+command] [-l] [-wn] [-x] name...
Description
The command displays a text file. The command and the command run almost the same code except that in changes to a file are not allowed.
It is possible to get to the command mode of from within both.
The following is a list of some of the commands. See the vi Beginner's Reference Card and the "Introduction to Display Editing with vi" in
the Supplementary Documents, Volume 1: General User for more details that can be helpful for using
Screen Control Commands
<CTRL/L> Reprints current screen.
<CTRL/Y> Exposes one more line at top of screen.
<CTRL/E> Exposes one more line at bottom of screen.
Paging Commands
<CTRL/F> Pages forward one screen.
<CTRL/B> Pages back one screen.
<CTRL/D> Pages down half screen.
<CTRL/U> Pages up half screen.
Cursor Positioning Commands
j Moves cursor down one line, same column.
k Moves cursor up one line, same column.
h Moves cursor back one character.
l Moves cursor forward one character.
<RETURN> Moves cursor to beginning of next line.
0 Moves cursor to beginning of current line.
$ Moves cursor to end of current line.
<SPACE> Moves cursor forward one character.
nG Moves cursor to beginning of line n. Default is last line of file.
/pattern Moves cursor forward to next occurrence of pattern.
?pattern Moves cursor backward to next occurrence of pattern.
n Repeats last / or ? pattern search.
Exiting view
ZZ Exits
:q Quits session.
Options-t tag Specifies a list of tag files. The tag files are preceded by a backslash () and are separated by spaces. The tag option should
always be the first entry.
+command Tells the editor to begin by executing the specified command. An example would be +/pattern that would search for a pattern.
-l Sets the showmatch and lisp options for viewing LISP code..
-r Retrieves the last saved version of the name'd file in the event of a system crash. If no file is specified, a list of saved
files is produced.
-wn Sets the default window size to n. This option is useful for starting in a small window on dialups. The -x option is available
only if the Encryption layered product is installed.
-x Causes to prompt for a key. The key is used to encrypt and decrypt the contents of the file. If the file has been encrypted
with one key, you must use the same key to decrypt the file.
See Alsoedit(1), ex(1), vi(1)
The Little Gray Book: An ULTRIX Primer
The Big Gray Book: The Next Step with ULTRIX
"An Introduction to Display Editing with vi" in the Supplementary Documents, Volume 1: General User
view(1)