Skip to content

Instantly share code, notes, and snippets.

View niemyjski's full-sized avatar
😀

Blake Niemyjski niemyjski

😀
View GitHub Profile
@niemyjski
niemyjski / configuration.yaml
Created December 26, 2019 22:21 — forked from AdamNaj/about.md
Z Wave Graph for Home Assistant
panel_custom:
- name: zwavegraph2
sidebar_title: Z-Wave Graph
sidebar_icon: mdi:access-point-network
url_path: zwave
@niemyjski
niemyjski / test.cs
Created December 20, 2019 11:05
json.net system.version bug with .net core 3.1
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Globalization;
using System.Text;
using Exceptionless.Core.Extensions;
using Exceptionless.Core.Models;
using Exceptionless.Core.Models.Data;
using Exceptionless.Serializer;
using Foundatio.Serializer;
@niemyjski
niemyjski / CancelErrorByMessageAndType.cs
Created December 3, 2019 13:57
Exceptionless.Net Cancel Error By Message And Type
[Priority(21)]
public class CancelErrorByMessageAndType : IEventPlugin {
public void Run(EventPluginContext context) {
// Only check error events.
if (context.Event.Type != Event.KnownTypes.Error)
return;
var error = context.Event.GetError();
if (error == null)
return;
@niemyjski
niemyjski / clean_code.md
Created August 26, 2019 20:02 — forked from wojteklu/clean_code.md
Summary of 'Clean code' by Robert C. Martin

Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.


General rules

  1. Follow standard conventions.
  2. Keep it simple stupid. Simpler is always better. Reduce complexity as much as possible.
  3. Boy scout rule. Leave the campground cleaner than you found it.
  4. Always find root cause. Always look for the root cause of a problem.

Design rules

@niemyjski
niemyjski / CodeSmith Tools CLA
Last active June 26, 2019 12:06
CodeSmith Tools CLA
**CodeSmith Tools, LLC Contributor License Agreement**
The document below clarifies the terms under which You (the copyright owner or legal entity authorized by the copyright owner), may make “The Contributions” (software, bug fixes, configuration changes, documentation, or any other materials) to “The Work” (codesmithtools/templates or codesmithtools/schemahelper). This license protects You, “The Company” (CodeSmith Tools, LLC) and licensees; it does not change your rights to use your own contributions for any other purpose.
Please complete the following information about You and The Contributions. If you have questions about these terms, please contact us at team@codesmithtools.com.
**You and “The Company” (CodeSmith Tools, LLC) agree:**
1. **You grant to “The Company” (CodeSmith Tools, LLC) a non-exclusive, irrevocable, worldwide, royalty-free, sublicenseable, relicenseable, transferable license** under all of Your relevant intellectual property rights, to use, copy, prepare derivative works of, distri
@niemyjski
niemyjski / satoshistreasure.md
Created April 18, 2019 16:42 — forked from johncantrell97/satoshistreasure.md
How I Obtained Satoshi's Treasure Keys 1, 2, and 3 in Minutes

Today (April 16th 2019 at noon) the first major clues to discover key #1 was set to be released in a few cities. A QR code with the words 'orbital' were found at these locations and looked like this: (https://imgur.com/a/6rNmz7T). If you read the QR code with your phone you will be directed to this url: https://satoshistreasure.xyz/k1

At this URL you are prompted to input a passphrase to decrypt the first shard. An obvious first guess was to try the word 'orbital' from the QR code. Not suprisingly this worked! This reveals a congratulations page and presents the first key shard:

ST-0001-a36e904f9431ff6b18079881a20af2b3403b86b4a6bace5f3a6a47e945b95cce937c415bedaad6c86bb86b59f0b1d137442537a8.

Now, we were supposed to wait until April 17th to get clues from the other cities for keys #2 and #3 but that wouldn't stop me from digging around with all the new information we had. All that time "playing" notpron (http://notpron.org/notpron/) years ago was going to help me here.

The first thing I noticed was

@niemyjski
niemyjski / app.js
Created February 19, 2019 19:09 — forked from rfletcher/app.js
A simple bridge between iMessage and Home Assistant's conversation component
const HomeAssistant = require( 'homeassistant' );
const Pino = require( 'pino' );
const config = require( 'config' );
const hass = new HomeAssistant( config.get( 'home_assistant' ) );
const imessage = require( 'osa-imessage' );
const logger = Pino();
// TODO package this better
const bridge = {
@niemyjski
niemyjski / dotnetlayout.md
Created February 21, 2018 14:15 — forked from davidfowl/dotnetlayout.md
.NET project structure
$/
  artifacts/
  build/
  docs/
  lib/
  packages/
  samples/
  src/
 tests/
@niemyjski
niemyjski / minio-gateway-azure.bat
Created February 8, 2018 17:23 — forked from harshavardhana/minio-gateway-azure.bat
Minio windows batch examples
rem This program starts the minio batch.
@echo off
setlocal
path=C:\programs\minio;%path%
set MINIO_ACCESS_KEY=accountname1
set MINIO_SECRET_KEY=secretForAccountName
call minio gateway azure --address=:9001 >c:\test\c1.out
endlocal
@niemyjski
niemyjski / CLA.md
Last active May 30, 2017 13:22
Exceptionless Contributor License Agreement

Exceptionless Contributor License Agreement

The document below clarifies the terms under which You (the copyright owner or legal entity authorized by the copyright owner), may make “The Contributions” (software, bug fixes, configuration changes, documentation, or any other materials) to “The Work” (Exceptionless/Exceptionless). This license protects You, “The Company” (Exceptionless) and licensees; it does not change your rights to use your own contributions for any other purpose.

Please complete the following information about You and The Contributions. If you have questions about these terms, please contact us at team@exceptionless.com.

You and “The Company” (Exceptionless) agree:

  1. You grant to “The Company” (Exceptionless) a non-exclusive, irrevocable, worldwide, royalty-free, sublicenseable, relicenseable, transferable license under all of Your relevant intellectual property rights, to use, copy, prepare derivative works of, distribute and publicly perform and display “The Contributions”