Skip to content

Instantly share code, notes, and snippets.

Jeffry van de Vuurst jeffryvu

View GitHub Profile
@jeffryvu
jeffryvu / jenkins-get-changelog.sh
Created Feb 12, 2015
Bash script to get the changelog from a certain jenkins build, format it in a nice way and write it to a properties file.
View jenkins-get-changelog.sh
# Based on http://stackoverflow.com/questions/11823826/get-access-to-build-changelog-in-jenkins
# Get changelog and format it properly
CHANGELOG=$(curl "http://localhost:8080/job/MyProject/$UPSTREAM_BUILD_NUMBER/api/xml?wrapper=changes&xpath=//changeSet//comment" | sed -e "s/<\/comment>//g; s/<comment>/* /g; s/<\/*changes>//g" | sed '/^$/d;G')
# Write result to properties file
echo CHANGELOG=$CHANGELOG > build.properties
@jeffryvu
jeffryvu / xamarin-testcloud-upload.sh
Last active Aug 29, 2015
Bash script to upload iOS app to Xamarin Test Cloud. Use together with xamarin-build.sh
View xamarin-testcloud-upload.sh
function section_print {
echo "\n=== $* ==="
}
# Parameter passed from the upstream job that built the iOS app
cd "$UPSTREAM_WORKSPACE"
for file in "*.ipa"
do
IPA_FILE=`echo $file`
@jeffryvu
jeffryvu / xamarin-build.sh
Created Feb 6, 2015
Bash script used by Jenkins to do a Xamarin.iOS build
View xamarin-build.sh
# !/bin/sh
# By Anonymous user on Stack Overflow
# Freely translated from https://nicolasgoles.com/blog/2011/08/continuous-integration-with-jenkins/
function fail {
echo "$*" >&2
exit 1
}
function section_print {
@jeffryvu
jeffryvu / xamarin_uitest_ios_simulator.cs
Last active Aug 29, 2015
Shows how to run a Xamarin UITest on an iOS simulator
View xamarin_uitest_ios_simulator.cs
IApp app = ConfigureApp
.iOS
.EnableLocalScreenshots()
.DeviceIdentifier("E67C54DA-17B2-4EBC-AA08-FBF3FB571243") // iPhone 6, 8.1
.AppBundle(PathToIPA)
.StartApp();
@jeffryvu
jeffryvu / xamarin_uitest_ios_device.cs
Last active Aug 29, 2015
Shows how to run a Xamarin UITest on an iOS device
View xamarin_uitest_ios_device.cs
IApp app = ConfigureApp
.iOS
.EnableLocalScreenshots()
.InstalledApp("com.example.yourappbundleid")
.DeviceIp("192.168.1.1")
.StartApp();
You can’t perform that action at this time.