Skip to content

Instantly share code, notes, and snippets.

public String getTapjoyDeviceID()
{
String udid = null;
// Try to get IMEI/MEID.
TelephonyManager telephonyManager = (TelephonyManager)context.getSystemService(Context.TELEPHONY_SERVICE);
if (telephonyManager != null)
{
String imei = telephonyManager.getDeviceId();
if (imei != null)
#if __IPHONE_OS_VERSION_MAX_ALLOWED >= __IPHONE_6_0
#import <AdSupport/AdSupport.h>
#endif
#include <sys/socket.h>
#include <sys/sysctl.h>
#include <net/if.h>
#include <net/if_dl.h>
#define SYSTEM_VERSION_GREATER_THAN_OR_EQUAL_TO(v) ([[[UIDevice currentDevice] systemVersion] compare:v options:NSNumericSearch] != NSOrderedAscending)
#!/bin/bash
# Example install script for monolithic/all-in-one PE Master in the 2016 or 2017 or 2018 series
# This version for Enterprise Linux (CentOS, RHEL, etc).
# This script assumes that networking, hostname, DNS, etc are all working.
if [ $# -ne 2 ]; then
echo "Wrong number of arguments. Expected 2 and got $#"
echo "Usage: $0 [<PE Version>|latest] <PE GUI admin password>"
exit 3
fi