Skip to main content
8 votes
Accepted

Upgrade Firefox Quantum from tarball

Pretty nice script, I have mostly minor suggestions. Always double-quote variables used in command arguments The parameters in these command should be double-quoted to protect from word splitting ...
janos's user avatar
  • 112k
7 votes
Accepted

Interactive Linux upgrade script

...
Gao's user avatar
  • 1,120
5 votes
Accepted

Simple Linux upgrade script in Bash

The output of your script is lovely, but it strikes me as a work in progress. There's nothing wrong with what is there, but it seems a few major pieces are missing. error checking What happens if ...
chicks's user avatar
  • 2,861
5 votes

Install, configure, and maintain content for Ubuntu webserver

So, this might not be quite in line with your 100% automation approach, but the best way to provide a shell script access to a git repository is to use ssh keys to allow access to your git repository. ...
RubberDuck's user avatar
  • 30.8k
4 votes
Accepted

Arch linux installation script to be reviewed for any leakage of personal / security info

Some notes: This script is really very brittle. It'll break if any of the tools change in any significant way, if your disk layout changes (see below), or if the sequence of steps for whatever reason ...
l0b0's user avatar
  • 8,977
4 votes
Accepted

Install Python script requirements

!!! Use this at your own risk. Fiddling with user's packages is scary business !!! You can monkey-patch the builtin import statement and upon encountering ...
FirefoxMetzger's user avatar
4 votes

Upgrade script for MediaWiki website with one external addon (wave 1)

Make the process approach atomic The script first wipes out ${war}/${domain}, then populates it with content from wget commands,...
janos's user avatar
  • 112k
4 votes
Accepted

Installing packages when needed

When quoting a list of symbols, it's redundant to quote each symbol within the list. There's no need to eval a symbol. This sequence looks strange: ...
Toby Speight's user avatar
  • 81.7k
3 votes

Arch linux installation script to be reviewed for any leakage of personal / security info

Your echo "multi-line input" | fdisk /dev/sda command is horrendous to read and maintain. The Arch Linux wiki page about partitioning states: fdisk (util-linux) ...
200_success's user avatar
3 votes
Accepted

Powershell Script to remove printers and drivers

Before relying on old VBS scripts, it pays to check what native PowerShell tools you have available: ...
Dangph's user avatar
  • 1,683
3 votes
Accepted

Batch bash installer script for clean Ubuntu GNOME installation

Wall of code The script looks like a wall of code. It would be a lot more pleasant to read if related groups of commands were separated from each other by blank lines, for example: ...
janos's user avatar
  • 112k
3 votes
Accepted

Webapp Substrate script for WordPress on Debian-Nginx

The outer heredoc construct isn't really required. You do not verify that you have command line arguments. You do not assign your command line arguments to the variable ...
user157887's user avatar
3 votes

Dynamic software update system using PHP

The biggest problem I see with this code is the extreme level at which you intermingle your browser output with your PHP logic. Developing in this way is going to lead to a codebase that is nearly ...
Mike Brant's user avatar
  • 9,638
3 votes

Ansible playbook to install application from tarball

(I know, reviving an OLD post, but the info I am sharing should be helpful to anyone new to Ansible that ends up here.) You're playbook looks pretty good, well done! There are a few minor things that ...
0xSheepdog's user avatar
3 votes
Accepted

Bash script to setup new Debian installs

Welcome to Code Review! It is a good practice if you start verifying your shell scripts against shellcheck. Currently, it lists quite a few issues: ...
hjpotter92's user avatar
  • 8,791
3 votes
Accepted

Interactive Linux upgrade script - Follow-up #1

This looks pretty good already, I don't have anything major to add, only some ideas: POSIX only supports short options. If a command and its short options are defined in the POSIX specifications, e.g....
Gao's user avatar
  • 1,120
3 votes
Accepted

Installing the VC Redistributable (2015|2017|2019) for both x86 and x64 using Inno Setup

I tested your code, Please move lines in PrepareToInstall method to BeforeDownload method: ...
JingYu's user avatar
  • 46
3 votes
Accepted

Upgrade Firefox Quantum with logging and version check

To sudo or not to sudo I'm also wondering if it's better to only run the commands that need it with sudo or if I should rerun ...
janos's user avatar
  • 112k
3 votes

Upgrade script for MediaWiki website with one external addon (wave 1)

You should save all files that are downloaded by wget in a local directory, either called distfiles, or ...
Roland Illig's user avatar
  • 21.4k
2 votes

Automated owncloud installation script

Naming Some of the function names could be improved, for example this one: ...
janos's user avatar
  • 112k
2 votes

Dockerfile to install Apache

Old question but you can do a lot to reduce the size of your final image (RUN, COPY and ADD ...
masseyb's user avatar
  • 146
2 votes
Accepted

LXC Bootstrap - A wrapper script around lxc utility scripts to create and set up an LXC container based on settings

I think you are using classes wrong. You use them only to have nice namespaces and do all the stuff you would normally do as methods outside of the class. And then you suppress the warnings about non-...
Graipher's user avatar
  • 41.1k
2 votes
Accepted

Simple Linux upgrade script in Bash revision 2

Don't use non-portable terminal escape codes The tput program exists for exactly this purpose: ...
Toby Speight's user avatar
  • 81.7k
2 votes

Interactive Linux upgrade script

This is sad to see: ...
Toby Speight's user avatar
  • 81.7k
2 votes
Accepted

Install, configure, and maintain content for Ubuntu webserver

Readability The script is hard to read because code blocks are not indented, and there are not blank lines to separate cohesive units. Consider this alternative writing style of the same script: <...
janos's user avatar
  • 112k
2 votes
Accepted

Bash script which downloads the latest linux stable kernel

Good stuff: Yay for putting your code on github. I see a lot of folks afraid to wait until everything is perfect to do that. But having the backup and history of git is too handy to wait like that. ...
chicks's user avatar
  • 2,861
2 votes

Nginx-WordPress installer for Debian

@cas has already pointed out the most critical issues. I add a few minor points on top of that. Syntax errors A semicolon is missing before the fi on this line ...
janos's user avatar
  • 112k
2 votes

Nginx-WordPress installer for Debian

My answer is going to focus on your use of shell functions and global variables. There aren't any actual syntax errors in your script AFAICT, but your misuse of functions in this script is ...
cas's user avatar
  • 234
2 votes
Accepted

Shell install.sh for repository (rpi_videoloop)

Pointless sudo When some dependencies are missing, the script installs them using apt-get install, without ...
janos's user avatar
  • 112k

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