Skip to content

Instantly share code, notes, and snippets.

<log4net>
<root>
<level value="ALL" />
<appender-ref ref="file" />
</root>
<appender name="file" type="log4net.Appender.RollingFileAppender">
<file type="log4net.Util.PatternString" value="%envFolderPath{MyDocuments}\NWESG\GameLogs\log-%property{ATimeStamp}.log" />
<appendToFile value="true" />
<rollingStyle value="Size" />
<maxSizeRollBackups value="5" />
@nikhilsinha
nikhilsinha / EnumToIntExample.java
Created March 3, 2019 23:27
Java 8 enum to int example
enum DaysOfWeek
{
Monday (5),
Tuesday (8);
private final int integralValue;
DaysOfWeek(int dayOfWeek){
integralValue = dayOfWeek;
}
Starting cloud-init: Cloud-init v. 0.7.6 running 'modules:final' at Wed, 08 Nov 2017 20:13:08 +0000. Up 38.44 seconds.
+ yum update -y aws-cfn-bootstrap
Loaded plugins: priorities, update-motd, upgrade-helper
No packages marked for update
+ /opt/aws/bin/cfn-init -v --stack Jenkins-Test-20171108 --resource JenkinsServer --configsets install_all --region us-east-1
+ wget --no-cookies --header 'Cookie: gpw_e24=xxx; oraclelicense=accept-securebackup-cookie;' http://download.oracle.com/otn-pub/java/jdk/8u144-b01/090f390dda5b47b9b721c7dfaa008135/jdk-8u144-linux-x64.rpm
--2017-11-08 20:13:15-- http://download.oracle.com/otn-pub/java/jdk/8u144-b01/090f390dda5b47b9b721c7dfaa008135/jdk-8u144-linux-x64.rpm
Resolving download.oracle.com (download.oracle.com)... 23.215.130.50, 23.215.130.59, 23.215.130.40
Connecting to download.oracle.com (download.oracle.com)|23.215.130.50|:80... connected.
HTTP request sent, awaiting response... 302 Moved Temporarily
@nikhilsinha
nikhilsinha / UiUnitAttacher.cs
Created January 2, 2017 01:40
With the hack
using UnityEngine;
public class UiUnitAttacher : MonoBehaviour
{
public GameObject Target;
private RectTransform _rectTransform;
// Use this for initialization
void Start()
{
using UnityEngine;
public class UiUnitAttacher : MonoBehaviour
{
public GameObject Target;
private RectTransform _rectTransform;
// Use this for initialization
void Start()
{
_rectTransform = GetComponent<RectTransform>();