Skip to content

Instantly share code, notes, and snippets.

View dnery's full-sized avatar

Danilo Nery dnery

View GitHub Profile
@dnery
dnery / CreateNewFile.ahk
Created April 14, 2021 00:05
AutoHotkey script to create a new file in the current folder
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
#Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
GetActiveExplorerPath()
{
explorerHwnd := WinActive("ahk_class CabinetWClass")
if (explorerHwnd)
{
@dnery
dnery / keybase.md
Created September 18, 2016 20:13
GitHub identity proof for keybase

Keybase proof

I hereby claim:

  • I am dnery on github.
  • I am dnery (https://keybase.io/dnery) on keybase.
  • I have a public key whose fingerprint is B1E6 6914 ECC4 DE96 E051 6BAA 9076 DDE2 0B0D B278

To claim this, I am signing this object:

@dnery
dnery / solution-279.erl
Last active October 26, 2025 20:02
dailyprogrammer #279 solution attempt in erlang
- module(solution).
- export([prettify/1,reflow/1,justify/1]).
% module entry point
%
prettify(A) -> lists:concat
(justify(reflow(re:split(A, "\\s+", [{return, list}])))).
% reflow calculator function
%
@dnery
dnery / solution-279.hs
Last active October 26, 2025 20:02
dailyprogrammer #279 solution attempt in haskell
import Data.List
import Data.List.Utils -- cabal install missingH
-- solution.hs
-- reflow and justify input text to 40-char width.
-- redir the output to a formatting function, so
-- results can actually be seen. e.g.:
-- putStrLn(prettify "sample text")
-- curryfying function