Development Journal

Deploying with Git Hooks


For a very lightweight deployment mechanism, consider Git Hooks.

For example, add the following to the file .git/hooks/post-commit:

	  #!/bin/sh
	  scp html/* myserver.example.com:~/html/
	  
After every commit the files in html will be copied synchronously to myserver.example.com.

Enabling Visual Styles for Win32 Common Controls


Add this pragma to the main.c file
#pragma comment(linker, \
"\"/manifestdependency:type='Win32' "\
"name='Microsoft.Windows.Common-Controls' "\
"version='6.0.0.0' "\
"processorArchitecture='*' "\
"publicKeyToken='6595b64144ccf1df' "\
"language='*'\"")

#pragma comment(lib, "ComCtl32.lib")

Building wxWidgets on Windows with Visual Studio 2010 or above

By default wxWidgets will build as a static library only. Add the SHARED=1 to override

To debug with shared libraries but release with a static binary, build wxWidgets as follows and update your linker options accordingly.

	WXWIN = C:\wxWidgets-3.0.5
	CD C:\wxWidgets-3.0.5\build\msw
	nmake /f makefile.vc BUILD=debug SHARED=1
	nmake /f makefile.vc BUILD=release