mirror of
https://github.com/nvbn/thefuck.git
synced 2025-01-18 12:06:04 +00:00
Fix install script on non-ubuntu
This commit is contained in:
parent
6df772ba05
commit
8bf4182f86
@ -4,8 +4,12 @@ should_add_alias () {
|
||||
[ -f $1 ] && ! grep -q thefuck $1
|
||||
}
|
||||
|
||||
installed () {
|
||||
hash $1 2>/dev/null
|
||||
}
|
||||
|
||||
# Install os dependencies:
|
||||
if [ -f $(which apt-get) ]; then
|
||||
if installed apt-get; then
|
||||
# Debian/ubuntu:
|
||||
sudo apt-get update -yy
|
||||
sudo apt-get install -yy python-pip python-dev command-not-found
|
||||
@ -15,7 +19,7 @@ if [ -f $(which apt-get) ]; then
|
||||
sudo apt-get install -yy python-commandnotfound
|
||||
fi
|
||||
else
|
||||
if [ -f $(which brew) ]; then
|
||||
if installed brew; then
|
||||
# OS X:
|
||||
brew update
|
||||
brew install python
|
||||
|
@ -8,7 +8,7 @@ RUN apt-get update
|
||||
RUN apt-get install -yy bash
|
||||
'''), (u'bash', 'generic-bash', u'''
|
||||
FROM fedora:latest
|
||||
RUN dnf install -yy python-devel sudo which gcc
|
||||
RUN dnf install -yy python-devel sudo wget gcc
|
||||
'''))
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user