Skip to content

Instantly share code, notes, and snippets.

View DanielAdeniji's full-sized avatar

Daniel Adeniji DanielAdeniji

View GitHub Profile
@DanielAdeniji
DanielAdeniji / makewinCustomized.cmd
Created March 9, 2020 17:38
netcat on MS Windows - makewinCustomized.cmd
@REM Build script to compile Netcat on WIN32 using MinGW
@REM
@REM Rodney Beede (http://www.rodneybeede.com)
@REM
@REM 2009-09-02
@REM
@REM Tested with gcc 3.4.5 and MinGW version 5.1.4
setlocal
@DanielAdeniji
DanielAdeniji / pruneGoogleCacheJavaScript.cmd
Created April 4, 2020 02:58
Google Chrome - Cache - Javascript - Clean up
@echo off
setlocal
set "_appData=%APPDATA%"
set "_appDataLocal=%LOCALAPPDATA%"
set "_googleChromeCodeCacheJS=%_appDataLocal%\Google\Chrome\User Data\Default\Code Cache\js"
dir "%_googleChromeCodeCacheJS%" | findstr "bytes" | findstr "File"
@DanielAdeniji
DanielAdeniji / helloWorldInRust.rs
Created June 6, 2021 20:37
Hello World in Rust
fn main()
{
println!("Hello, world!");
}
@DanielAdeniji
DanielAdeniji / helloWorld.java
Last active January 1, 2022 18:26
helloWorldInJava
public class helloWorld
{
public static void main(String[] args)
{
// Prints "Hello, World" to the terminal window.
System.out.println("Hello, World");
}
}
@DanielAdeniji
DanielAdeniji / compile.cmd
Last active January 3, 2022 00:37
helloLog4J
setlocal
set "jar_log4j_version=2.17.1"
set "jar_log4j_explicit=lib/log4j/*"
set "jar_log4j_implicit=lib/log4j/log4j-api-%jar_log4j_version%.jar;lib/log4j/log4j-core-%jar_log4j_version%.jar;lib/log4j/log4j-1.2-api-%jar_log4j_version%.jar"
set "jar_log4j=%jar_log4j_implicit%"
rem Adding Comments
rem https://www.nobody.com/?a=1
IF %ERRORLEVEL% NEQ 0 Echo errorlevel is %ERRORLEVEL%
@DanielAdeniji
DanielAdeniji / repeatChar.powershell.function.eitherOr.ps1
Created May 5, 2022 18:47
Calling Powershell function with commas
[string] $title;
[char] $ch;
[int] $len=0;
[string] $filler = "";
[boolean] $bCallFunctionWithComma = $false;
function repeatChar([char] $ch,[int] $n)
{
[String] $str = "";
@DanielAdeniji
DanielAdeniji / repeatChar.js
Last active May 15, 2022 02:49
repeat Character in Node JS
/*
Function:- repeatChar
*/
function repeatChar(ch, count)
{
/*
Declare buffer as an array
*/
var buffer = [];
var str = "";
Set-StrictMode -Version Latest
<#
Declare Person Object
#>
class person
{
[string] $name;
@DanielAdeniji
DanielAdeniji / stringCollectionDump.cs
Created June 1, 2022 12:16
Printing out the contents of a string collection
using System.IO;
using System;
using System.Linq;
class Program
{
enum enumConversionChoice
{
convertToStringArray