Skip to content

Instantly share code, notes, and snippets.

View augustoproiete's full-sized avatar
👨‍💻
shipping it :shipit: from home 🏠

C. Augusto Proiete augustoproiete

👨‍💻
shipping it :shipit: from home 🏠
View GitHub Profile
@augustoproiete
augustoproiete / testharness.py
Created July 9, 2016 15:01 — forked from tintoy/testharness.py
Logging to Seq from Python 3
#!/usr/bin/env python3
import datetime
import logging
import requests
# Well-known keyword arguments used by the logging system.
_well_known_logger_kwargs = [
"extra",
"exc_info",
@augustoproiete
augustoproiete / month-name-in-portuguese-using-liquid-jekyll.liquid
Last active March 8, 2019 19:14
Printing month name in Portuguese using Liquid/Jekyll
{% assign m = page.date | date: "%-m" %}
{% capture month_name_pt %}
{% case m %}
{% when '1' %}Janeiro
{% when '2' %}Fevereiro
{% when '3' %}Março
{% when '4' %}Abril
{% when '5' %}Maio
{% when '6' %}Junho
{% when '7' %}Julho
@augustoproiete
augustoproiete / SimpleHttpServer.cs
Created December 20, 2015 20:50
C# Based HttpListener Static File Web Server
using System;
using System.Collections.Generic;
using System.Net.Sockets;
using System.Net;
using System.IO;
using System.Threading;
using System.Windows.Forms;
using Westwind.Utilities;
namespace Westwind.WebConnection
using System;
using System.Diagnostics;
using System.Runtime.InteropServices;
using System.Text;
using System.Threading;
namespace Caio.Proiete.Utils
{
public class SilentProcessRunner : IDisposable
{
@augustoproiete
augustoproiete / App.config
Created October 27, 2015 01:23
Example of using custom prefixes with Serilog when using AppSettings
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<appSettings>
<add key="custom1:serilog:minimum-level" value="Warning" />
<add key="custom2:serilog:minimum-level" value="Error" />
</appSettings>
</configuration>

Keybase proof

I hereby claim:

  • I am caioproiete on github.
  • I am caioproiete (https://keybase.io/caioproiete) on keybase.
  • I have a public key whose fingerprint is 06E3 2C7B EE28 4DE5 F315 B43B 8BB1 65D1 FD13 745D

To claim this, I am signing this object:

@augustoproiete
augustoproiete / teamcity-metarunner-to-use-special-version-for-nuget.xml
Last active March 24, 2021 01:21
Example of a TeamCity meta-runner that updates the build.version variable and provides other variants of version variables, such as a special version for NuGet
<?xml version="1.0" encoding="UTF-8"?>
<meta-runner name="Meta (CaioProiete): Initialize build and set custom parameters">
<description>Initialize the build and set the value of some custom parameters that can be used during the build, such as version, timestamp, and others</description>
<settings>
<parameters>
<param name="mr.initialize_build.releaseBranch" value="%build.releaseBranch%" spec="text label='Release Branch:' description='The name of the branch from where production releases are generated' display='normal' validationMode='not_empty'" />
<param name="mr.initialize_build.verbose" value="SilentlyContinue" spec="checkbox checkedValue='Continue' description='Log verbose messages?' display='normal' label='Verbose:' uncheckedValue='SilentlyContinue'" />
</parameters>
<build-runners>
<runner name="Initialize build and set custom parameters" type="jetbrains_powershell">
@augustoproiete
augustoproiete / gist:7e37ab5209a1a47d6ab0
Last active November 30, 2015 18:54 — forked from nblumhardt/gist:07c8046ffdcbd3d6b1fa
Configuring Serilog w/ AppSettings and Seq

1. Install Serilog.Extras.AppSettings

PM> Install-Package Serilog.Extras.AppSettings

2. Add the 'read' method to logger config

... = new LoggerConfiguration()
@augustoproiete
augustoproiete / License.txt
Created September 30, 2014 13:00
Example Unofficial NuGet Package for DevExpress Controls
DEVELOPER EXPRESS INC
DEVEXPRESS .NET Controls and Frameworks
Copyright (C) 2000-2014 Developer Express Inc.
END-USER LICENSE AGREEMENT
FOR ALL SOFTWARE DEVELOPMENT PRODUCT(S) INCLUDED IN THIS DISTRIBUTION
IMPORTANT- READ CAREFULLY: This DEVELOPER EXPRESS INC ("DEVEXPRESS") End-User License Agreement ("EULA") is a legal agreement between you, a developer of software applications, ("Developer End User") and DEVEXPRESS for all DEVEXPRESS products, frameworks, components, source code, demos, intermediate files, media, printed materials, and "online" or electronic documentation ("SOFTWARE DEVELOPMENT PRODUCT(S)") contained in this distribution.
By installing, copying, or otherwise using the SOFTWARE DEVELOPMENT PRODUCT(S), you agree to be bound by the terms of this EULA. If you do not agree to any part of the terms of this EULA, DO NOT INSTALL, COPY, USE, EVALUATE, OR REPLICATE IN ANY MANNER, ANY PART, FILE OR PORTION OF THE SOFTWARE DEVELOPMENT PRODUCT(S).