Tag Info

Hot answers tagged

4

Please realize that disabling the password prompt for sudo is a huge security concern. However, it is possible. Instead of what you already have, add this to your /etc/sudoers file: petruza ALL=(ALL) NOPASSWD: ALL Here is some more reading on this topic.


3

Either upgrade your bash (homebrew) or you'll have to recode it using a series of if statements: case "$OSTYPE" in linux-gnu*) ;;& linux*) echo $OSTYPE; ;; esac case "$OSTYPE" in linux-gnu*) ;& linux*) echo $OSTYPE; ;; esac would be # first case if [[ $OSTYPE == linux-gnu* ]]; then : # nothing in this branch fi if [[ $OSTYPE == linux* ]]; ...


3

Your Bash prompt is not properly escaped for non-printing characters, so it thinks the prompt is longer than it truly is (and doesn't delete some of the characters). To fix it, add \[ and \] around the invisible parts. You need to change it to: export PS1='\[\e[31m\]\W\[\e[0m\] '


3

The commands shown in the title indicate that something is being run. This is likely to be in a sourced file such as… ~/.bash_profile ~/.profile /etc/profile ~/.bash_login ~/.bashrc (although this is not sourced automatically) Check the files that your shell is sourcing for the commands that are being run and comment them out or remove them if necessary. ...


2

Read the current setting defaults read com.apple.BezelServices dAuto Write defaults write com.apple.BezelServices dAuto -boolean true/false


1

As aglasser commented, you can use textutil like so: create-codeblock | textutil -stdin -format html -convert rtf -stdout | pbcopy


1

Figured it out. It was as simple as replacing both words with $(ls *) So final command is: printf "From: Sender Name <sender@domain.com>\nTo: recipient@domain.com\nSubject: $(ls *)\n\n$(ls *)\n" | /usr/sbin/sendmail -F "Sender Name" -f "sender@domain.com" "recipient@domain.com"


1

You can install coreutils with brew install coreutils. shuf will be linked as gshuf. Read the caveats when you install coreutils.


1

easy_install is part of setuptools. There's a handy script to bootstrap it: curl https://bootstrap.pypa.io/ez_setup.py -o - | python You may need to put sudo before python if it throws a permissions error. There's a few more details here: https://pypi.python.org/pypi/setuptools#installation-instructions but that one-liner should do the trick in most ...



Only top voted, non community-wiki answers of a minimum length are eligible