I've downloaded a Virtual Machine once I open the terminal this message comes in front I've tried to download the bash manually still doesn't work well and the message still appears as follows;
bash: alias: do: not found
bash: alias: anything: not found
@Abdullah , welcome, we hope you find the forum friendly and helpful.
please respond to all requests - they are for our benefit to help you , we don't assume anything !
-
what is the OS (version, give memory sizes if know as well) you installed the VM on to ?
-
what VM did you download and install (name and version numbers ....)
-
when you say '...tried to download the bash manually still doesn't work....'
show those actions ( the commands you typed/executed to do that). please , provide copy/paste of the actual commands along with outputs - NO SCREENSHOTS - they are difficult to read, and preclude the team from copy/pasting to try themselves and hide embedded/non-printing characters.-
confirm you where doing those whilst within the VM machine environment
-
confirm if you were executing with elevated privileges or as a standard user
-
check in the .bash* config files for the presence of entries that could be the cause of the errors being thrown
-
- I'm using Windows 10 Home OS version
- the VM is oracle virtual Box version 6.1 operating system Ubuntu (64bit)
as well the error still appears per your request I have pasted the error as follows
bash: alias: do: not found
bash: alias: anything: not found
also I have tried to download the bash using [sudo apt install bash ] the result was as below;
Reading package lists... Done
Building dependency tree
Reading state information... Done
bash is already the newest version (5.0-6ubuntu1.2).
The following packages were automatically installed and are no longer required:
libfwupdplugin1 libxmlb1 ubuntu-advantage-desktop-daemon
Use 'sudo apt autoremove' to remove them.
0 to upgrade, 0 to newly install, 0 to remove and 3 not to upgrade
Do you get the error when you do
cd
source .bashrc
?
once writing [source .bashrc ] the message directly appears;
bash: alias: do: not found
bash: alias: anything: not found
What is its contents?
cat .bashrc
Anything with "do" and "anything" in there that cause that error message?
Any further "source" or "." commands in there that source further command files?
the command answer;
alias pymol='/home/user/Downloads/pymol
source ~/.bashrc
# ~/.bashrc: executed by bash(1) for non-login shells.
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
# for examples
# If not running interactively, don't do anything
case $- in
*i*) ;;
*) return;;
esac
# don't put duplicate lines or lines starting with space in the history.
# See bash(1) for more options
HISTCONTROL=ignoreboth
# append to the history file, don't overwrite it
shopt -s histappend
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
HISTSIZE=1000
HISTFILESIZE=2000
# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
shopt -s checkwinsize
# If set, the pattern "**" used in a pathname expansion context will
# match all files and zero or more directories and subdirectories.
#shopt -s globstar
# make less more friendly for non-text input files, see lesspipe(1)
[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"
# set variable identifying the chroot you work in (used in the prompt below)
if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then
debian_chroot=$(cat /etc/debian_chroot)
fi
# set a fancy prompt (non-color, unless we know we "want" color)
case "$TERM" in
xterm-color|*-256color) color_prompt=yes;;
esac
# uncomment for a colored prompt, if the terminal has the capability; turned
# off by default to not distract the user: the focus in a terminal window
# should be on the output of commands, not on the prompt
#force_color_prompt=yes
if [ -n "$force_color_prompt" ]; then
if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then
# We have color support; assume it's compliant with Ecma-48
# (ISO/IEC-6429). (Lack of such support is extremely rare, and such
# a case would tend to support setf rather than setaf.)
color_prompt=yes
else
color_prompt=
fi
fi
if [ "$color_prompt" = yes ]; then
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
else
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '
fi
unset color_prompt force_color_prompt
# If this is an xterm set the title to user@host:dir
case "$TERM" in
xterm*|rxvt*)
PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1"
;;
*)
;;
esac
# enable color support of ls and also add handy aliases
if [ -x /usr/bin/dircolors ]; then
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
alias ls='ls --color=auto'
#alias dir='dir --color=auto'
#alias vdir='vdir --color=auto'
alias grep='grep --color=auto'
alias fgrep='fgrep --color=auto'
alias egrep='egrep --color=auto'
fi
# colored GCC warnings and errors
#export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01'
# some more ls aliases
alias ll='ls -alF'
alias la='ls -A'
alias l='ls -CF'
# Add an "alert" alias for long running commands. Use like so:
# sleep 10; alert
alias alert='notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo error)" "$(history|tail -n1|sed -e '\''s/^\s*[0-9]\+\s*//;s/[;&|]\s*alert$//'\'')"'
# Alias definitions.
# You may want to put all your additions into a separate file like
# ~/.bash_aliases, instead of adding them here directly.
# See /usr/share/doc/bash-doc/examples in the bash-doc package.
if [ -f ~/.bash_aliases ]; then
. ~/.bash_aliases
fi
# enable programmable completion features (you don't need to enable
# this, if it's already enabled in /etc/bash.bashrc and /etc/profile
# sources /etc/bash.bashrc).
if ! shopt -oq posix; then
if [ -f /usr/share/bash-completion/bash_completion ]; then
. /usr/share/bash-completion/bash_completion
elif [ -f /etc/bash_completion ]; then
. /etc/bash_completion
fi
fi
alias R='/usr/bin/R'
alias igv='/home/manager/IGV_Linux_2.12.2/igv.sh'
alias genomescope='/home/manager/miniconda3/bin/genomescope.R'
alias genomescope.R='/home/manager/miniconda3/bin/genomescope.R'
export set PATH="/home/manager/miniconda2/bin:$PATH"
#export PKG_CONFIG_PATH=/usr/local/lib/x86_64-linux-gnu/pkgconfig
export _JAVA_OPTIONS=-Xmx512M
# >>> conda initialize >>>
# !! Contents within this block are managed by 'conda init' !!
__conda_setup="$('/home/manager/miniconda3/bin/conda' 'shell.bash' 'hook' 2> /dev/null)"
if [ $? -eq 0 ]; then
eval "$__conda_setup"
else
if [ -f "/home/manager/miniconda3/etc/profile.d/conda.sh" ]; then
. "/home/manager/miniconda3/etc/profile.d/conda.sh"
else
export PATH="/home/manager/miniconda3/bin:$PATH"
fi
fi
unset __conda_setup
# <<< conda initialize <<<
where is the closing ' for that alias ....
fix that then source the file again - works for me !
Thanks for your support I've installed Markdown_1.0.1 but still don't know how it works as well regarding to the closing of Pymol there is no application opened right know but it seems to me copy and paste via HTML is an easier way if you clarify some tricks around Markdown and how to use it I appreciate it.
@Abdullah,
the menu bar above where you type your dialog into has all the markdown options you need.
code is typically surrounded in 3 backticks , if you select the >_ option you can see that
What about your code error - have you edited the first line and added the missing quote?
_the error still the same once i've open a new terminal the code appears;
bash: alias: do: not found bash: alias: anything: not found
really,
show the file as is now by entering the following command please.
cat -vet .bashrc
then show
source .bashrc
thks
the first command >cat -vet .bashrc;
alias pymol='/home/user/Downloads/pymol$
source ~/.bashrc $
# ~/.bashrc: executed by bash(1) for non-login shells.$
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)$
# for examples$
$
# If not running interactively, don't do anything$
case $- in$
*i*) ;;$
*) return;;$
esac$
$
# don't put duplicate lines or lines starting with space in the history.$
# See bash(1) for more options$
HISTCONTROL=ignoreboth$
$
# append to the history file, don't overwrite it$
shopt -s histappend$
$
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)$
HISTSIZE=1000$
HISTFILESIZE=2000$
$
# check the window size after each command and, if necessary,$
# update the values of LINES and COLUMNS.$
shopt -s checkwinsize$
$
# If set, the pattern "**" used in a pathname expansion context will$
# match all files and zero or more directories and subdirectories.$
#shopt -s globstar$
$
# make less more friendly for non-text input files, see lesspipe(1)$
[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"$
$
# set variable identifying the chroot you work in (used in the prompt below)$
if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then$
debian_chroot=$(cat /etc/debian_chroot)$
fi$
$
# set a fancy prompt (non-color, unless we know we "want" color)$
case "$TERM" in$
xterm-color|*-256color) color_prompt=yes;;$
esac$
$
# uncomment for a colored prompt, if the terminal has the capability; turned$
# off by default to not distract the user: the focus in a terminal window$
# should be on the output of commands, not on the prompt$
#force_color_prompt=yes$
$
if [ -n "$force_color_prompt" ]; then$
if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then$
^I# We have color support; assume it's compliant with Ecma-48$
^I# (ISO/IEC-6429). (Lack of such support is extremely rare, and such$
^I# a case would tend to support setf rather than setaf.)$
^Icolor_prompt=yes$
else$
^Icolor_prompt=$
fi$
fi$
$
if [ "$color_prompt" = yes ]; then$
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '$
else$
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '$
fi$
unset color_prompt force_color_prompt$
$
# If this is an xterm set the title to user@host:dir$
case "$TERM" in$
xterm*|rxvt*)$
PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1"$
;;$
*)$
;;$
esac$
$
# enable color support of ls and also add handy aliases$
if [ -x /usr/bin/dircolors ]; then$
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"$
alias ls='ls --color=auto'$
#alias dir='dir --color=auto'$
#alias vdir='vdir --color=auto'$
$
alias grep='grep --color=auto'$
alias fgrep='fgrep --color=auto'$
alias egrep='egrep --color=auto'$
fi$
$
# colored GCC warnings and errors$
#export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01'$
$
# some more ls aliases$
alias ll='ls -alF'$
alias la='ls -A'$
alias l='ls -CF'$
$
# Add an "alert" alias for long running commands. Use like so:$
# sleep 10; alert$
alias alert='notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo error)" "$(history|tail -n1|sed -e '\''s/^\s*[0-9]\+\s*//;s/[;&|]\s*alert$//'\'')"'$
$
# Alias definitions.$
# You may want to put all your additions into a separate file like$
# ~/.bash_aliases, instead of adding them here directly.$
# See /usr/share/doc/bash-doc/examples in the bash-doc package.$
$
if [ -f ~/.bash_aliases ]; then$
. ~/.bash_aliases$
fi$
$
# enable programmable completion features (you don't need to enable$
# this, if it's already enabled in /etc/bash.bashrc and /etc/profile$
# sources /etc/bash.bashrc).$
if ! shopt -oq posix; then$
if [ -f /usr/share/bash-completion/bash_completion ]; then$
. /usr/share/bash-completion/bash_completion$
elif [ -f /etc/bash_completion ]; then$
. /etc/bash_completion$
fi$
fi$
$
$
alias R='/usr/bin/R'$
alias igv='/home/manager/IGV_Linux_2.12.2/igv.sh'$
alias genomescope='/home/manager/miniconda3/bin/genomescope.R'$
alias genomescope.R='/home/manager/miniconda3/bin/genomescope.R'$
export set PATH="/home/manager/miniconda2/bin:$PATH"$
$
#export PKG_CONFIG_PATH=/usr/local/lib/x86_64-linux-gnu/pkgconfig$
export _JAVA_OPTIONS=-Xmx512M$
# >>> conda initialize >>>$
# !! Contents within this block are managed by 'conda init' !!$
__conda_setup="$('/home/manager/miniconda3/bin/conda' 'shell.bash' 'hook' 2> /dev/null)"$
if [ $? -eq 0 ]; then$
eval "$__conda_setup"$
else$
if [ -f "/home/manager/miniconda3/etc/profile.d/conda.sh" ]; then$
. "/home/manager/miniconda3/etc/profile.d/conda.sh"$
else$
export PATH="/home/manager/miniconda3/bin:$PATH"$
fi$
fi$
unset __conda_setup$
# <<< conda initialize <<<$
$
$
the second > source .bashrc
bash: alias: do: not found bash: alias: anything: not found
you still haven't applied the single quote to the end of the line
alias pymol='/home/user/Downloads/pymol
needs to become
alias pymol='/home/user/Downloads/pymol'
until you do that - nothing will change
@Abdullah , ... and you're still not using markdown code tags. Please start doing so going forward. The Usage link was provided previously.
I'm sorry for being naive toward using the markdown I've downloaded a remarkable application as Markdown program maybe I'm can't know how to use it until know as i said before I'm just a newly training person on Linux sorry again for frustrating you about not trying a single quote which actually I did it and still the message is the same last time you asked me to close the quote with a comma and the result of this still the same;
manager@NGSBioAfrica2022:~$ alias pymol='/home/user/Downloads/pymol'
manager@NGSBioAfrica2022:~$ source .bashrc
bash: alias: do: not found
bash: alias: anything: not found
^C
manager@NGSBioAfrica2022:~$ cat -vet .bashrc
alias pymol='/home/user/Downloads/pymol$
source ~/.bashrc $
# ~/.bashrc: executed by bash(1) for non-login shells.$
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)$
# for examples$
$
# If not running interactively, don't do anything$
case $- in$
*i*) ;;$
*) return;;$
esac$
$
# don't put duplicate lines or lines starting with space in the history.$
# See bash(1) for more options$
HISTCONTROL=ignoreboth$
$
# append to the history file, don't overwrite it$
shopt -s histappend$
$
# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)$
HISTSIZE=1000$
HISTFILESIZE=2000$
$
# check the window size after each command and, if necessary,$
# update the values of LINES and COLUMNS.$
shopt -s checkwinsize$
$
# If set, the pattern "**" used in a pathname expansion context will$
# match all files and zero or more directories and subdirectories.$
#shopt -s globstar$
$
# make less more friendly for non-text input files, see lesspipe(1)$
[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)"$
$
# set variable identifying the chroot you work in (used in the prompt below)$
if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then$
debian_chroot=$(cat /etc/debian_chroot)$
fi$
$
# set a fancy prompt (non-color, unless we know we "want" color)$
case "$TERM" in$
xterm-color|*-256color) color_prompt=yes;;$
esac$
$
# uncomment for a colored prompt, if the terminal has the capability; turned$
# off by default to not distract the user: the focus in a terminal window$
# should be on the output of commands, not on the prompt$
#force_color_prompt=yes$
$
if [ -n "$force_color_prompt" ]; then$
if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then$
^I# We have color support; assume it's compliant with Ecma-48$
^I# (ISO/IEC-6429). (Lack of such support is extremely rare, and such$
^I# a case would tend to support setf rather than setaf.)$
^Icolor_prompt=yes$
else$
^Icolor_prompt=$
fi$
fi$
$
if [ "$color_prompt" = yes ]; then$
PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '$
else$
PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '$
fi$
unset color_prompt force_color_prompt$
$
# If this is an xterm set the title to user@host:dir$
case "$TERM" in$
xterm*|rxvt*)$
PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1"$
;;$
*)$
;;$
esac$
$
# enable color support of ls and also add handy aliases$
if [ -x /usr/bin/dircolors ]; then$
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"$
alias ls='ls --color=auto'$
#alias dir='dir --color=auto'$
#alias vdir='vdir --color=auto'$
$
alias grep='grep --color=auto'$
alias fgrep='fgrep --color=auto'$
alias egrep='egrep --color=auto'$
fi$
$
# colored GCC warnings and errors$
#export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01'$
$
# some more ls aliases$
alias ll='ls -alF'$
alias la='ls -A'$
alias l='ls -CF'$
$
# Add an "alert" alias for long running commands. Use like so:$
# sleep 10; alert$
alias alert='notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo error)" "$(history|tail -n1|sed -e '\''s/^\s*[0-9]\+\s*//;s/[;&|]\s*alert$//'\'')"'$
$
# Alias definitions.$
# You may want to put all your additions into a separate file like$
# ~/.bash_aliases, instead of adding them here directly.$
# See /usr/share/doc/bash-doc/examples in the bash-doc package.$
$
if [ -f ~/.bash_aliases ]; then$
. ~/.bash_aliases$
fi$
$
# enable programmable completion features (you don't need to enable$
# this, if it's already enabled in /etc/bash.bashrc and /etc/profile$
# sources /etc/bash.bashrc).$
if ! shopt -oq posix; then$
if [ -f /usr/share/bash-completion/bash_completion ]; then$
. /usr/share/bash-completion/bash_completion$
elif [ -f /etc/bash_completion ]; then$
. /etc/bash_completion$
fi$
fi$
$
$
alias R='/usr/bin/R'$
alias igv='/home/manager/IGV_Linux_2.12.2/igv.sh'$
alias genomescope='/home/manager/miniconda3/bin/genomescope.R'$
alias genomescope.R='/home/manager/miniconda3/bin/genomescope.R'$
export set PATH="/home/manager/miniconda2/bin:$PATH"$
$
#export PKG_CONFIG_PATH=/usr/local/lib/x86_64-linux-gnu/pkgconfig$
export _JAVA_OPTIONS=-Xmx512M$
# >>> conda initialize >>>$
# !! Contents within this block are managed by 'conda init' !!$
__conda_setup="$('/home/manager/miniconda3/bin/conda' 'shell.bash' 'hook' 2> /dev/null)"$
if [ $? -eq 0 ]; then$
eval "$__conda_setup"$
else$
if [ -f "/home/manager/miniconda3/etc/profile.d/conda.sh" ]; then$
. "/home/manager/miniconda3/etc/profile.d/conda.sh"$
else$
export PATH="/home/manager/miniconda3/bin:$PATH"$
fi$
fi$
unset __conda_setup$
# <<< conda initialize <<<$
$
@Abdullah ,
last attempt to assist you.
what is this ?, the .bashrc file now seems to be 1 line long with still the ?first/only line missing a single quote at the end of the alias.
cat -vet .bashrc alias pymol='/home/user/Downloads/pymol$
just noticed the line source ~/.bashrc ' seems to be within the .bashrc file ?, if so, it needs to be deleted
1 - edit the .bashrc file
2 - change the line
alias pymol='/home/user/Downloads/pymol
to
alias pymol='/home/user/Downloads/pymol'
a closing single quote has been added to the line
3 - DO NOT create any alias pymol outside of the .bashrc file
4 - save the file and return to the command prompt
5 - source .bashrc
No, you did NOT edit the .bashrc to add a missing quote - as you can see from your output above.
You simply set your alias BEFORE sourcing the .bashrc.
$ cat -vet .bashrc
alias pymol='/home/user/Downloads/pymol$
source ~/.bashrc$
you need to edit your .bashrc to add a quote as indicated previously.
Abdullah, on this part: no, you don't need any application at all, nor any special knowledge, to use markdown. All you have to do is to click in the ">_" button, just above the answer field. It will automatically create a pair of code format delimiters (```). Paste your code between them (leave each one in a line by themselves), and it will look like this in the end:
code