10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
how to Change the % prompt to - prompt in unix
:wall:
---------- Post updated at 07:40 AM ---------- Previous update was at 07:38 AM ----------
How To display the last modification time of any file in unix
---------- Post updated at 07:40 AM ---------- Previous update was at 07:40 AM... (2 Replies)
Discussion started by: manjiri sawant
2 Replies
2. Shell Programming and Scripting
I am trying to create my custom prompt and I have almost succeeded. Right now I have PS1='\n\\$\ '
What I have not figured out is how to make the directories bold when I'm using commands ls or ls -la.
Any idea how to do it???
Many thanx. (2 Replies)
Discussion started by: emailkia
2 Replies
3. Red Hat
Hello,
I installed Kerberos on Red Hat. My testing tool checks for the prompt when user log-in. Unfortunately I don't have access to that testing tool so I have to fix somehow the prompt.
My testing tool expects this format:
login: XYZ
Password:
When I installed Kerberos I have this format:... (1 Reply)
Discussion started by: susja
1 Replies
4. UNIX for Advanced & Expert Users
Hello,
I installed Kerberos on Red Hat. My testing tool checks for the prompt when user log-in. Unfortunately I don't have access to that testing tool so I have to fix somehow the prompt.
My testing tool expects this format:
login: XYZ
Password: When I installed Kerberos I have this format:... (1 Reply)
Discussion started by: susja
1 Replies
5. UNIX for Dummies Questions & Answers
Hi guys,
I got these 3 servers: a, b and c which I ssh from a to b/c.
a:$ ssh userid@b
Password:
a:$ ssh userid@c
userid@c's password:
Notice that the password prompt is different (highlighted in bold) on both servers even though their SUN Solaris version the same, OpenSSH version... (0 Replies)
Discussion started by: DrivesMeCrazy
0 Replies
6. UNIX for Dummies Questions & Answers
Hello all. I was wondering if there is a way to change the root prompt.
I am using Solaris 10 and would like to have the root prompt display the current directory along with 'SU' to indicate root status.
What I have tried so far:
/etc/passwd
changed the root shell to korn with... (10 Replies)
Discussion started by: RobertSubnet
10 Replies
7. Solaris
I'm on a Solaris 8 box that is not prompting users to change their password after it has expired. I have an older Solaris 8 box that does. We're accessing both via ssh. We have recently built the box that doesn't prompt from scratch. Obviously, we've overlooked something but we don't know what.... (2 Replies)
Discussion started by: mark24p
2 Replies
8. UNIX for Dummies Questions & Answers
I have a Sun OS and at the moment the prompt is # and i want to change it to:
root@server #
can you help me please. thanks in advance. (4 Replies)
Discussion started by: drogram
4 Replies
9. Solaris
Hi all,
I was wondering how to change the PS1 to my liking?
I tried changing it using PS1='my choice'
it worked but the subsequent terminals i open will not have it as the default PS1 ,how do i change it?
also i am running as super user, and i need to exec bash, to get the bash environment...... (4 Replies)
Discussion started by: wrapster
4 Replies
10. Shell Programming and Scripting
I want to write a shell script which will change the current shell (say from csh to bsh) and my Prompt (say my name) as desired.pls help (1 Reply)
Discussion started by: SHYAM
1 Replies
GIT-SH(1) GIT-SH(1)
NAME
git-sh -- a git shell
SYNOPSIS
git-sh
DESCRIPTION
git-sh starts an interactive bash(1) session modified for git-heavy workflows. Typical usage is to change into the directory of a git work
tree or bare repository and run the git-sh command to start an interactive shell session.
Top-level command aliases are created for all core git(1) subcommands, git-sh builtin aliases (see BUILTIN ALIASES), and git command
aliases defined in ~/.gitconfig.
BUILTIN ALIASES
git-sh loads a set of standard aliases in addition to all core git commands. The builtin aliases are overridden by aliases defined in the
user or system gitconfig files.
a git add
b git branch
c git checkout
d git diff
f git fetch --prune
k git cherry-pick
l git log --pretty=oneline --abbrev-commit
n git commit --verbose --amend
r git remote
s git commit --dry-run --short
t git diff --cached
The Staging Area
a git add
aa git add --update (mnemonic: "add all")
stage git add
ap git add --patch
p git diff --cached (mnemonic: "patch")
ps git diff --cached --stat (mnemonic: "patch stat")
unstage
git reset HEAD
Commits and Commit History
ci git commit --verbose
ca git commit --verbose --all
amend git commit --verbose --amend
n git commit --verbose --amend
k git cherry-pick
re git rebase --interactive
pop git reset --soft HEAD^
peek git log -p --max-count=1
Fetching and Pulling
f git fetch
pm git pull (mnemonic: "pull merge")
pr git pull --rebase (mnemonic: "pull rebase")
Miscellaneous Commands
d git diff
ds git diff --stat (mnemonic: "diff stat")
hard git reset --hard
soft git reset --soft
scrap git checkout HEAD
CUSTOM ALIASES
Anything defined in the [alias] section of the repository, user, or system git config files are also available as top-level shell commands.
Assuming a ~/.gitconfig that looked like this:
[alias]
ci = commit --verbose
ca = commit -a
d = diff
s = status
thanks = !git-thanks
... you might then have the following shell session:
master!something> echo "stuff" >somefile
master!something*> s
M somefile
master!something*> d
diff --git a/somefile b/somefile
-- a/somefile
++ b/somefile
@@ -0,0 +1 @@
+ stuff
master!something*> ca -m "add stuff"
master!something> thanks HEAD
PROMPT
The default prompt shows the current branch, a bang (!), and then the relative path to the current working directory from the root of the
work tree. If the work tree includes modified files that have not yet been staged, a dirty status indicator (*) is also displayed.
The git-sh prompt includes ANSI colors when the git color.ui option is set and enabled. To enable git-sh's prompt colors explicitly, set
the color.sh config value to auto:
$ git config --global color.sh auto
Customize prompt colors by setting the color.sh.branch, color.sh.workdir, and color.sh.dirty git config values:
$ git config --global color.sh.branch 'yellow reverse'
$ git config --global color.sh.workdir 'blue bold'
$ git config --global color.sh.dirty 'red'
See colors in git for information.
COMPLETION
Bash completion support is automatically enabled for all git built-in commands and also for aliases defined in the user ~/.gitconfig file.
The auto-completion logic is smart enough to know an alias d that expands to git-diff should use the same completion configuration as the
git-diff command.
The completion code is a slightly modified version of the git bash completion script shipped with the core git distribution. The script is
built into thegit-sh executable at compile time and need not be obtained or installed separately.
CUSTOMIZING
Most git-sh behavior can be configured by editing the user or system gitconfig files (~/.gitconfig and /etc/gitconfig) either by hand or
using git-config(1). The [alias] section is used to create basic command aliases.
The /etc/gitshrc and ~/.gitshrc files are sourced (in that order) immediately before the shell becomes interactive.
The ~/.bashrc file is sourced before either /etc/gitshrc or ~/.gitshrc. Any bash customizations defined there and not explicitly overrid-
den by git-sh are also available.
ENVIRONMENT
PS1 Set to the dynamic git-sh prompt. This can be customized in the ~/.gitshrc or /etc/gitshrc files.
GIT_DIR
Explicitly set the path to the git repository instead of assuming the nearest .git path.
GIT_WORK_TREE
Explicitly set the path to the root of the work tree instead of assuming the nearest parent directory with a .git repository.
SEE ALSO
bash(1), git(1), git-config(1),http://github.com/rtomayko/git-sh
Ryan Tomayko March 2010 GIT-SH(1)