Skip to content

Instantly share code, notes, and snippets.

View SyntaxC4's full-sized avatar
🏠
Working from home

Cory Fowler SyntaxC4

🏠
Working from home
View GitHub Profile
@SyntaxC4
SyntaxC4 / .user.ini
Last active December 20, 2015 06:09
ZendGuard .user.ini file for Windows Azure Web Sites
[WinCache]
wincache.fcenabled=Off
[ZendGuard]
;zend_loader.enable=1
;zend_loader.disable_licensing=0
;zend_loader.obfuscation_level_support=3
;zend_loader.license_path=
@SyntaxC4
SyntaxC4 / wincache.php
Created August 23, 2013 07:07
This Gist contains the sample code which is available on http://windowsazurewebsitescheatsheet.info.
<?php
/*
+----------------------------------------------------------------------------------------------+
| Windows Cache for PHP |
+----------------------------------------------------------------------------------------------+
| Copyright (c) 2009, Microsoft Corporation. All rights reserved. |
| |
| Redistribution and use in source and binary forms, with or without modification, are |
| permitted provided that the following conditions are met: |
| - Redistributions of source code must retain the above copyright notice, this list of |
@SyntaxC4
SyntaxC4 / SetPHPVersion.ps1
Created September 23, 2013 09:49
Explicitly Set PHP Version for a Windows Azure Web Site
Set-AzureWebsite -PhpVersion 5.3 -Name <site-name>
@SyntaxC4
SyntaxC4 / config.hdf
Last active December 28, 2015 04:48
Upstart script for hhVM on Ubuntu 13.04
Server {
SourceRoot = /var/www
}
@SyntaxC4
SyntaxC4 / change-post-git-colors.md
Last active December 30, 2021 09:10
Changing Colors in Posh-Git

Changing color settings in Poshgit

  1. Navigate to the Poshgit Install Directory

    • [Chocolatey] C:\tools\Poshgit\dahlbyk-posh-git-9d624ca\
    • [Local User] %UserProfile%\Documents\WindowsPowerShell\Modules\Poshgit
    • [System] %windir%\System32\WindowsPowerShell\Modules\Poshgit
  2. Right-Click on GitPrompt.ps1 and select Edit

  3. Between line 5 and 39 you will find all of the colour settings

@SyntaxC4
SyntaxC4 / Microsoft.PowerShell_profile.ps1
Created February 2, 2014 23:48
PowerShell Prompt for LOST fans...
# It's your choice if you want to enter the code and press the button.
# >: 4 8 15 16 23 42
function prompt {
write-host '>:' -nonewline
return ' '
}
@SyntaxC4
SyntaxC4 / composer.json
Last active August 29, 2015 13:56
Interacting with the Windows Azure Management API with Guzzle PHP
{
"require": {
"guzzle/guzzle": "~3.1"
}
}
@SyntaxC4
SyntaxC4 / PostBuildEvent
Last active August 29, 2015 13:57
This target file can be used to deploy WebJobs via WebDeploy (Visual Studio Publish)
rem Replace [WebProjectName] with the name of your Web Application project name
xcopy "$(TargetDir)*.*" "$(SolutionDir)[WebProjectName]\App_Data\jobs\continuous\$(ProjectName)\" /y
@SyntaxC4
SyntaxC4 / Clear-WebPICache.ps1
Last active August 29, 2015 13:57
Windows Azure Boot Camp (Training) Resource Kit
gci -Force "$env:localappdata\Microsoft\Web Platform Installer" | Remove-Item -Recurse -Force
gci -Force "$env:appdata\Microsoft\Web Platform Installer" | Remove-Item -Recurse -Force
@SyntaxC4
SyntaxC4 / Create-Primary-Environment.ps1
Last active August 29, 2015 13:59
Environment Setup for Dev/Test
function Get-ScriptDirectory {
$Invocation = (Get-Variable MyInvocation -Scope 1).Value
Split-Path $Invocation.MyCommand.Path
}
$FunctionToRegister = Join-Path (Get-ScriptDirectory) "setup\Invoke-AzureEnvironmentSetup.ps1"
. "$FunctionToRegister"
#### Primary Environment
$EnvironmentSubscriptionName = "Primary Subscription Name"