<!- .... ->
<log4net>
<appender name="RollingLogFileAppenderLogstash" type="log4net.Appender.RollingFileAppender">
<encoding value="utf-8" />
<!--该目录必需有 IIS用户 写权限-->
<file value="X:/var/log/[app_name]/logfile.log" />
<appendToFile value="true" />
<rollingStyle value="Date" />
<lockingModel type="log4net.Appender.FileAppender+MinimalLock" />
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[TestFixture] | |
public class QuerySomeView | |
{ | |
[Test] | |
public void DoIt() | |
{ | |
var context = new StoreContext(); | |
var results = context.Database.SqlQuery<ReadModel>("SELECT * FROM SomeView").ToList(); | |
Assert.AreEqual(results.Count(), 2); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let fslex = @"packages\FSPowerPack.Community.2.1.3.1\Tools\fslex.exe" | |
let parserDir = @".\LiteMedia.Dsl\" | |
// FsParse | |
Target "FsYacc" (fun _ -> | |
let result = | |
ExecProcess (fun info -> | |
info.FileName <- fsyacc | |
info.Arguments <- parserDir + "parser.fsy --module Parser" | |
) (System.TimeSpan.FromMinutes 1.) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace Unplugged | |
{ | |
public abstract class ListPickerViewModel<TItem> : UIPickerViewModel | |
{ | |
public TItem SelectedItem { get; private set; } | |
IList<TItem> _items; | |
public IList<TItem> Items | |
{ | |
get { return _items; } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This is how you add a Jenkins slave | |
# On master: | |
sudo -u jenkins -H ssh-keygen | |
# On slave | |
adduser --system --group --home=/var/lib/jenkins-slave --no-create-home --disabled-password --quiet --shell /bin/bash jenkins-slave | |
install -d -o jenkins-slave -g jenkins-slave /var/lib/jenkins-slave |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static System.IO.Stream ResizeAndRotate(string filePath, int maxWidth, int maxHeight, float jpegQuality) | |
{ | |
// loads just the dimensions of the file instead of the entire image | |
var options = new BitmapFactory.Options { InJustDecodeBounds = true }; | |
BitmapFactory.DecodeFile (filePath, options); | |
int outHeight = options.OutHeight; | |
int outWidth = options.OutWidth; | |
int inSampleSize = 1; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -ex | |
# Originally from https://gist.github.com/jedi4ever/b1f8b27d4a803d487fa4 | |
# This scripts allows you to upload a binary to the iTunes Connect Store and do it for a specific app_id | |
# Because when you have multiple apps in status for download, xcodebuild upload will complain that multiple apps are in wait status | |
# Requires application loader to be installed | |
# See https://developer.apple.com/library/ios/documentation/LanguagesUtilities/Conceptual/iTunesConnect_Guide/Chapters/SubmittingTheApp.html |
title | subtitle | author | date | source |
---|---|---|---|---|
Build, Publish and Deploy ASP.NET Web Applications from the Command Line |
How to use the MSBuild (or dotnet) command to build, publish, deploy ASP.NET web applications from the command line. |
Microsoft |
December 12, 2019 |
NOTE: Content below is written by Adrian Mace. Click here for an updated version.
Below are the key settings that I apply on any unifi installation for optimal performance.
- Ensure
Enable Advanced Features
is enabled
This allows you to follow along with the guide in it's entirety.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
partNo=$1 | |
storeId=$2 | |
notifyUrl=https://ntfy.sh/$3 | |
FILE=$4/${partNo/\//-}-$storeId | |
if [ ! -f "$FILE" ]; then | |
echo "$FILE does not exist." | |
echo -n "1" > $FILE | |
fi |
OlderNewer