Skip to content

Instantly share code, notes, and snippets.

View Azaferany's full-sized avatar
🎯
Focusing

Ali Zaferany Azaferany

🎯
Focusing
View GitHub Profile
@aRmanNM
aRmanNM / docker-compose.yml
Created December 23, 2022 08:40
grafana + prometheus + node_exporter
version: '3.8'
networks:
monitoring:
driver: bridge
volumes:
prometheus_data: {}
grafana_data: {}
@Azaferany
Azaferany / Program.cs
Created June 1, 2022 13:38
Microsoft RulesEngine Demo
using Newtonsoft.Json;
using RulesEngine.Models;
while (true)
{
string text = System.IO.File.ReadAllText(@"./workflow.json");
var workflowRules = JsonConvert.DeserializeObject<Workflow[]>(text);
var reSettings = new ReSettings()
{
@ds1371dani
ds1371dani / gridify.ts
Last active September 21, 2022 03:14
Gridify query builder for typescript
import { GridifyConditionEnum, GridifyLogicalEnum, GridifyOrderEnum, FilterType, OperatorType, FiltersType } from "./types.ts";
function trimEnds(query: string): string {
let result = query;
// There should not be any starting or ending operator
if (result.startsWith(GridifyLogicalEnum.And)) result = result.slice(GridifyLogicalEnum.And.length);
if (result.startsWith(GridifyLogicalEnum.Or)) result = result.slice(GridifyLogicalEnum.Or.length);
if (result.endsWith(GridifyLogicalEnum.And)) result = result.slice(0, -GridifyLogicalEnum.And.length);
if (result.endsWith(GridifyLogicalEnum.Or)) result = result.slice(0, -GridifyLogicalEnum.Or.length);
return result;
Console.WriteLine("Hello World!?");
Console.WriteLine("Minimal Test For Github Gist");
@joshbuchea
joshbuchea / semantic-commit-messages.md
Last active May 4, 2024 17:49
Semantic Commit Messages

Semantic Commit Messages

See how a minor change to your commit message style can make you a better programmer.

Format: <type>(<scope>): <subject>

<scope> is optional

Example