Skip to content

Instantly share code, notes, and snippets.

@KingsleyOmon-Edo
KingsleyOmon-Edo / post_install.sh
Created October 23, 2017 23:43 — forked from waleedahmad/post_install.sh
Ubuntu post installation script for installing software of your choice.
#!/bin/bash
curl_check ()
{
echo "Checking for curl..."
if command -v curl > /dev/null; then
echo "Detected curl..."
else
echo "Installing curl..."
apt-get install -q -y curl
@KingsleyOmon-Edo
KingsleyOmon-Edo / fedora-27-post-install.sh
Created November 16, 2017 07:05
A post installation script for fedora 27
#!/bin/bash
curl_check ()
{
echo "Checking for curl..."
if command -v curl > /dev/null; then
echo "Detected curl..."
else
echo "Installing curl..."
dnf install -y curl
@KingsleyOmon-Edo
KingsleyOmon-Edo / class_logger.asp
Created November 22, 2017 19:48 — forked from CarlRevell/class_logger.asp
Simple classic ASP log to file class.
<%
'// Usage:
'//
'// dim l : set l = new logger
'// l.log("Hello")("World")
'// l.includeTimetamp = false
'// l("Lorem ipsum")
'// l.setLogFile("c:\temp\log_2.log").log("This is a new log!")
'// set l = nothing
#add 'node_modules' to .gitignore file
git rm -r --cached node_modules
git commit -m 'Remove the now ignored directory node_modules'
git push origin master
@KingsleyOmon-Edo
KingsleyOmon-Edo / ubuntu-17.10-post-install.sh
Last active August 15, 2018 22:29
A post installation script for installing selected application on Ubuntu 17.10.
#!/bin/bash
curl_check ()
{
echo "Checking for curl..."
if command -v curl > /dev/null; then
echo "Detected curl..."
else
echo "Installing curl..."
apt-get install -q -y curl
@KingsleyOmon-Edo
KingsleyOmon-Edo / Ninject.Http.cs
Created February 12, 2018 20:01 — forked from odytrice/Ninject.Http.cs
A small Library to configure Ninject (A Dependency Injection Library) with a WebAPI Application.
using Ninject.Modules;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
using System.Web;
using System.Web.Http;
using System.Web.Http.Dependencies;
// A small Library to configure Ninject (A Dependency Injection Library) with a WebAPI Application.
@KingsleyOmon-Edo
KingsleyOmon-Edo / Ninject.Mvc.cs
Created February 12, 2018 20:03 — forked from odytrice/Ninject.Mvc.cs
A small Library to configure Ninject (A Dependency Injection Library) with an ASP.NET Application.
using Ninject;
using Ninject.Modules;
using Ninject.Web.Common;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
using System.Web;
using System.Web.Mvc;
@KingsleyOmon-Edo
KingsleyOmon-Edo / google-fonts.sh
Created March 8, 2018 02:53 — forked from dyoungwd/google-fonts.sh
Install Google Fonts on fedora
# Original : Michalis Georgiou
# Modified : D4zzy for Fedora
_wgeturl="https://github.com/google/fonts/archive/master.tar.gz"
_gf="google-fonts"
# install wget
echo "Installing wget..."
sudo dnf install wget
<configuration>
<config>
<add key="repositoryPath" value="..\lib" />
</config>
</configuration>
@KingsleyOmon-Edo
KingsleyOmon-Edo / TransformWebConfigForProduction.ps1
Created May 19, 2018 07:56 — forked from GeorgDangl/TransformWebConfigForProduction.ps1
Deploying Asp.Net Core Applications from Jenkins to IIS or Azure via WebDeploy
$environmentName = "Production"
# Applying web.config transformations
$webConfigTransformatorPackages = Join-Path -Path $env:USERPROFILE -ChildPath "\.nuget\packages\WebConfigTransformRunner"
$latestWebConfigTranformator = Join-Path -Path ((Get-ChildItem -Path $webConfigTransformatorPackages | Sort-Object Fullname -Descending)[0].FullName) -ChildPath "Tools\WebConfigTransformRunner.exe"
$webConfigDirs = Get-ChildItem -Path "$PSScriptRoot\publish" -Recurse -Filter "web*.config" | Select -Property Directory -Unique
ForEach ($directory in $webConfigDirs.Directory){
$transformationSource = (Get-ChildItem -Path $directory -Filter ("web." + $environmentName + ".config"))
if ($transformationSource) {
$guid = [Guid]::NewGuid().ToString()