Skip to content

Instantly share code, notes, and snippets.

View VijayChavda's full-sized avatar

Vijay Chavda VijayChavda

View GitHub Profile
@stefanbc
stefanbc / perms.md
Last active July 15, 2024 00:57
Set proper permissions on /var/www/

HOWTO

To set up permissions on /var/www where your files are served from by default:

sudo addgroup webmasters
sudo adduser $USER webmasters
sudo chown -R root:webmasters /var/www
sudo find /var/www -type f -exec chmod 664 {} \;
sudo find /var/www -type d -exec chmod 775 {} \;
@schuster-rainer
schuster-rainer / RelayCommand.cs
Created May 9, 2012 21:17
Implementation from Josh Smith of the RelayCommand
//http://msdn.microsoft.com/en-us/magazine/dd419663.aspx#id0090030
public class RelayCommand : ICommand
{
#region Fields
readonly Action<object> _execute;
readonly Predicate<object> _canExecute;
#endregion // Fields