Last active
April 6, 2020 15:06
-
-
Save aamnah/93cb63fc15e708649084 to your computer and use it in GitHub Desktop.
Revisions
-
aamnah revised this gist
Jul 24, 2017 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -28,7 +28,7 @@ Color_Off='\033[0m' # Text Reset } # Ask for version echo -e "${Cyan} What version should i install? (for example: ${BCyan}1.5.6.4${Cyan} or ${BCyan}3.0.2.0${Cyan})${Color_Off}" read VERSION checkVersion -
aamnah revised this gist
Jul 24, 2017 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -15,7 +15,7 @@ Color_Off='\033[0m' # Text Reset checkVersion() { # check if version provided is a valid OpenCart release version_list=("3.0.2.0" "3.0.1.2" "3.0.1.1" "3.0.0.0" "2.3.0.2" "2.3.0.1" "2.3.0.0" "2.2.0.0" "2.1.0.2" "2.1.0.1" "2.0.3.1" "2.0.2.0" "2.0.1.1" "2.0.1.0" "2.0.0.0" "1.5.6.4" "1.5.6.3" "1.5.6.2" "1.5.6.1" "1.5.6" "1.5.5.1" "1.5.4.1" "1.5.4") match=0 for v in "${version_list[@]}" -
aamnah revised this gist
Feb 26, 2015 . 1 changed file with 21 additions and 5 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -13,17 +13,32 @@ Red='\033[0;31m' # Red BCyan='\033[1;36m' # Bold Cyan Color_Off='\033[0m' # Text Reset checkVersion() { # check if version provided is a valid OpenCart release version_list=("2.0.1.1" "2.0.1.0" "2.0.0.0" "1.5.6.4" "1.5.6.3" "1.5.6.2" "1.5.6.1" "1.5.6" "1.5.5.1" "1.5.4.1" "1.5.4") match=0 for v in "${version_list[@]}" do if [[ $v = "$VERSION" ]]; then match=1 break fi done } # Ask for version echo -e "${Cyan} What version should i install? (for example: ${BCyan}1.5.6.4${Cyan} or ${BCyan}2.0.1.1${Cyan})${Color_Off}" read VERSION checkVersion if [[ $match = 0 ]]; then echo -e "${Red} Not a valid OpenCart version. Exiting.. ${Color_Off}" return 0 fi if [[ $match = 1 ]]; then # Download files for that version from Github echo -e "${Cyan} Downloading files.. ${Color_Off}" wget -O opencart-$VERSION.zip https://codeload.github.com/opencart/opencart/zip/$VERSION @@ -40,4 +55,5 @@ Color_Off='\033[0m' # Text Reset echo -e "${Green} Opencart was successfully copied. Please run the install script to finish installation. \n http://yourdomain.com/install \n ${Color_Off}" return 1 fi -
aamnah revised this gist
Feb 26, 2015 . 1 changed file with 25 additions and 16 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -9,26 +9,35 @@ # COLORS Cyan='\033[0;36m' # Cyan Green='\033[0;32m' # Green Red='\033[0;31m' # Red BCyan='\033[1;36m' # Bold Cyan Color_Off='\033[0m' # Text Reset version_list=[2.0.1.1, 2.0.1.0, 2.0.0.0, 1.5.6.4, 1.5.6.3, 1.5.6.2, 1.5.6.1, 1.5.6, 1.5.5.1, 1.5.4.1, 1.5.4] # Ask for version echo -e "${Cyan} What version should i install? (for example: ${BCyan}1.5.6.4${Cyan} or ${BCyan}2.0.1.1${Cyan})${Color_Off}" read VERSION # check if version provided is a valid release if ! [ $VERSION in version_list ]; then echo -e "${Red} Not a valid OpenCart version. Exiting.. ${Color_Off}" return 1 else # Download files for that version from Github echo -e "${Cyan} Downloading files.. ${Color_Off}" wget -O opencart-$VERSION.zip https://codeload.github.com/opencart/opencart/zip/$VERSION echo -e "${Cyan} Extracting.. ${Color_Off}" tar zxvf opencart-$VERSION.zip echo -e "${Cyan} Cleaning up.. ${Color_Off}" mv opencart-$VERSION/* . rm -rf opencart-$VERSION.zip opencart-$VERSION mv upload/* . mv upload/.htaccess.txt ./.htaccess rmdir upload echo -e "${Green} Opencart was successfully copied. Please run the install script to finish installation. \n http://yourdomain.com/install \n ${Color_Off}" fi -
aamnah revised this gist
Feb 26, 2015 . 1 changed file with 1 addition and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -31,5 +31,4 @@ mv upload/.htaccess.txt ./.htaccess rmdir upload echo -e "${Green} Opencart was successfully copied. Please run the install script to finish installation. \n http://yourdomain.com/install \n ${Color_Off}" -
aamnah revised this gist
Feb 26, 2015 . 1 changed file with 4 additions and 3 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -17,13 +17,13 @@ echo -e "${Cyan} What version should i install? (for example: ${BCyan}1.5.6.4${C read VERSION # Download files for that version from Github echo -e "${Cyan} Downloading files.. ${Color_Off}" wget -O opencart-$VERSION.zip https://codeload.github.com/opencart/opencart/zip/$VERSION echo -e "${Cyan} Extracting.. ${Color_Off}" tar zxvf opencart-$VERSION.zip echo -e "${Cyan} Cleaning up.. ${Color_Off}" mv opencart-$VERSION/* . rm -rf opencart-$VERSION.zip opencart-$VERSION mv upload/* . @@ -32,3 +32,4 @@ rmdir upload echo -e "${Green} Opencart was successfully copied. Please run the install script to finish installation. \n http://yourdomain.com/install \n ${Color_Off}" } -
aamnah revised this gist
Feb 17, 2015 . 1 changed file with 7 additions and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -6,8 +6,14 @@ # Usage: You can use 'curl' to run this script directly from Github. # curl -L https://gist.github.com/aamnah/93cb63fc15e708649084/raw | bash # COLORS Cyan='\033[0;36m' # Cyan Green='\033[0;32m' # Green BCyan='\033[1;36m' # Bold Cyan Color_Off='\033[0m' # Text Reset # Ask for version echo -e "${Cyan} What version should i install? (for example: ${BCyan}1.5.6.4${Cyan} or ${BCyan}2.0.1.1${Cyan})${Color_Off}" read VERSION # Download files for that version from Github -
aamnah revised this gist
Feb 17, 2015 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -7,7 +7,7 @@ # curl -L https://gist.github.com/aamnah/93cb63fc15e708649084/raw | bash # Ask for version echo -e "${Cyan} What version should i install? (for example: 1.5.6.4 or 2.0.1.1)${Color_Off}" read VERSION # Download files for that version from Github -
aamnah revised this gist
Feb 17, 2015 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -7,7 +7,7 @@ # curl -L https://gist.github.com/aamnah/93cb63fc15e708649084/raw | bash # Ask for version echo -e "${Cyan} What version should i install? (for example '1.5.6.4' or '2.0.1.1')${Color_Off}" read VERSION # Download files for that version from Github -
aamnah revised this gist
Feb 17, 2015 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -4,7 +4,7 @@ # Email: [email protected] # Description: Bash script to install Opencart # Usage: You can use 'curl' to run this script directly from Github. # curl -L https://gist.githubusercontent.com/aamnah/93cb63fc15e708649084/raw | bash # Ask for version echo -e "${Cyan} What version should i install? ('1.5.6.4' or '2.0.1.1')${Color_Off}" -
aamnah created this gist
Feb 17, 2015 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,28 @@ #!/bin/bash # Author: Aamnah Akram # URL: http://aamnah.com # Email: [email protected] # Description: Bash script to install Opencart # Usage: You can use 'curl' to run this script directly from Github. # curl -L http://gist.url | bash # Ask for version echo -e "${Cyan} What version should i install? ('1.5.6.4' or '2.0.1.1')${Color_Off}" read VERSION # Download files for that version from Github echo -e "$ {Cyan}Downloading files.. ${Color_Off}" wget -O opencart-$VERSION.zip https://codeload.github.com/opencart/opencart/zip/$VERSION echo -e "$ {Cyan}Extracting.. ${Color_Off}" tar zxvf opencart-$VERSION.zip echo -e "$ {Cyan}Cleaning up.. ${Color_Off}" mv opencart-$VERSION/* . rm -rf opencart-$VERSION.zip opencart-$VERSION mv upload/* . mv upload/.htaccess.txt ./.htaccess rmdir upload echo -e "${Green} Opencart was successfully copied. Please run the install script to finish installation. \n http://yourdomain.com/install \n ${Color_Off}"