Skip to content

Instantly share code, notes, and snippets.

View gnerkus's full-sized avatar
⌨️

Ifeanyi Oraelosi gnerkus

⌨️
View GitHub Profile
@gnerkus
gnerkus / minimalref.xml
Created November 28, 2024 08:16
Minimal API expanded MSBuild
This file has been truncated, but you can view the full file.
<!--
============================================================================================================================================
D:\Projects\App-Workspace\Csharp\minimalref\minimalref.csproj
============================================================================================================================================
-->
<Project DefaultTargets="Build">
<!--
============================================================================================================================================
<Import Project="Sdk.props" Sdk="Microsoft.NET.Sdk.Web">
This import was added implicitly because the Project element's Sdk attribute specified "Microsoft.NET.Sdk.Web".
@gnerkus
gnerkus / minimalref.log
Created November 28, 2024 07:56
Template Minimal API
Build started 11/28/2024 8:37:43.
Logging verbosity is set to: Normal. 1>Project "D:\Projects\App-Workspace\Csharp\minimalref\minimalref.csproj" on node 1 (build target(s)).
1>ResolveStaticWebAssetsConfiguration:
Creating directory "obj\Debug\net8.0\staticwebassets\".
GenerateTargetFrameworkMonikerAttribute:
Skipping target "GenerateTargetFrameworkMonikerAttribute" because all output files are up-to-date with respect to the input files.
CoreGenerateAssemblyInfo:
Skipping target "CoreGenerateAssemblyInfo" because all output files are up-to-date with respect to the input files.
_DiscoverMvcApplicationParts:
Could not infer the type of parameter "#1" because the attribute type is unknown. The value will be treated as a string.
@gnerkus
gnerkus / CreatingIdentityTables.cs
Created October 21, 2024 09:57
Migration to add ASP NET Identity relations
using System;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace streak.Migrations
{
/// <inheritdoc />
public partial class CreatingIdentityTables : Migration
{
@gnerkus
gnerkus / constructor_check.js
Created September 22, 2015 07:13
Verify object instance has instance attributes defined using Esprima
// This file is to executed in a Nodejs environment.
// `node constructor_check.js`
'use strict';
// You'll need to install the 'esprima', 'estraverse' and 'lodash' modules via npm.
var esprima = require('esprima');
var estraverse = require('estraverse');
var fs = require('fs');
var path = require('path');
var _ = require('lodash');
@gnerkus
gnerkus / Recursive Find
Created February 10, 2013 04:06
Search for a character in an iterable and return an index of all occurrences of that character.
def recursvfind (search, target, start=0, pos=[]):
current_pos = str(target).find(search, start)
if current_pos < 0:
return pos
else:
return recursvfind(search, target, current_pos + 1, pos + [current_pos])