Skip to content

Instantly share code, notes, and snippets.

View qtraw.awk
BEGIN {
FS = "\n" # 4.5.5 Making the Full Line Be a Single Field
# line_re = "^(In|Out)[[]([0-9]+)[]]: (.*)"
# line_re = /(In |Out).([0-9]+).: (.*)/
line_re = "^(In |Out)[[]([0-9]*)[]]: (.*)$"
}
# /^In/ {
# st = substr($0,index($0,':') + 1);
@RockyRoad29
RockyRoad29 / instances.dot
Last active Dec 31, 2017
Draw a graph of multiple instances of same project
View instances.dot
/*
Did you ever hatively make different checkouts of the same project
to test a feature, describe a bug, or whatever reason, and then forget to clean up or tidy
them afterwards ? After a while, it could get difficult to find your way ...
This example graph could help me a lot to visualize which is what, what could cause problems
when upgrading, and to correct things.
It should be easy enough to use as a base to describe your own data.
*/
@RockyRoad29
RockyRoad29 / html-divs-to-org-headings.1.el
Created Dec 13, 2017
WIP:Convert (pandoc generated) HTML divs to org headings with properties
View html-divs-to-org-headings.1.el
;; [WIP] DISCLAIMER This is a work in progress.
;; Don't use unless you really know what you're doing,
;; and under your sole responsibility.
;; Again, THIS CODE IS WITHOUT WARRANTY OF ANY KIND.
;;
;; [AUTHOR] (c) 2017 Michelle Baert , under GPL-3.0 license.
;;
;; -------------------------------------------------------------------------
;; [GLOBALS] For convenience, this code uses a few global variables, that you can define
;; in your *scratch* buffer or any other elisp context.
@RockyRoad29
RockyRoad29 / rr-js2.el
Created Nov 19, 2017
Emacs js2-mode hook - Avoid "Code has no side effect" warnings in tests using chaijs
View rr-js2.el
;; Get rid of extraneous warnings from js2-mode when using chai test library, e.g.
;; expect(o.loaded).to.be.false;
;; triggers "Code has no side effect"
;;
;; This is just a workaround: such messages will be removed for the whole file.
(defun rr-js2-tests-filter-warnings ()
(setq js2-parsed-warnings
(let (rslt)
(dolist (e js2-parsed-warnings (reverse rslt))
@RockyRoad29
RockyRoad29 / .spacemacs.el
Created Feb 23, 2017
[spacemacs] dotfile
View .spacemacs.el
;; -*- mode: emacs-lisp -*-
;; gnu/linux - Spacemacs: 0.200.7@25.1.1 - branch: develop (rev. 0c8af9686)
;; <2017-02-23 Thu>
;; ------------------------------------------------------------------------
;; This file is loaded by Spacemacs at startup.
;; It must be stored in your home directory.
(defun dotspacemacs/layers ()
"Configuration Layers declaration.
You should not put any user code in this function besides modifying the variable
values."
@RockyRoad29
RockyRoad29 / chatting-windows.el
Last active Dec 31, 2017
[emacs] chatting windows - Some functions for visually picking lines from a buffer in another window.
View chatting-windows.el
;;; chatting-windows.el --- Some functions for visually picking lines from a buffer in another window.
;; Copyright (C) 2008..2017 Michelle Baert
;; Author: Michelle Baert
;; Keywords:
;; This file is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation; either version 2, or (at your option)
@RockyRoad29
RockyRoad29 / README.org
Last active Feb 13, 2020
Emacs loaded packages exploration tools
View README.org

Exploring your loaded emacs libraries (spacemacs)

lpkg-explorer

file:lpkg-explorer.el These functions are designed basically for use in a lisp interaction session, where more variants may easily be tailored for your needs .

My main purpose here is to detect potential org-mode conflicts between built-in (typically older) and user local versions.

View bug-org-link-types.org
@RockyRoad29
RockyRoad29 / vtt-clean2.awk
Last active Jan 4, 2017
Extract text from .vtt format subtitles (e.g. youtube) trying to group text chunks in phrases, while retaining their position.
View vtt-clean2.awk
#!/usr/bin/awk -f
# --------------------------------------------------------
# Extracts text from .vtt format subtitles (e.g. youtube)
# trying to group text chunks in phrases, and output
# each set along with its start time position.
#
# Of course you will likely need to polish it manually,
# but this would be a helpful start.
#
# Debugging traces are prefixed with "!" for easy filtering.