Skip to content

Instantly share code, notes, and snippets.

@cverbiest
cverbiest / list_indexstat.p
Last active August 29, 2015 14:22
OpenEdge _IndexStat csv export
/*
Code to generate csv file from _IndexStat
Comment from George Potemkin
https://community.progress.com/community_groups/openedge_rdbms/f/18/p/17913/65295.aspx#65295
This program uses the _IndexStat-split and _IndexStat-blockdelete fields.
Due to a Progress bug the value of "blockdelete" field is always zero and the value in "split" field is incorrect.
The same is true for _UserIndexStat and for promon. They all read the correct bytes in shared memory.
It's the Progress clients who update a wrong counter when a block is deleted (freed) from index tree.
routefile=$(mktemp)
route > $routefile 2>&1
zenity --text-info --font='Monospace 8' --filename=$routefile --height=480 --width=700
" allow backspacing over everything in insert mode
set backspace=indent,eol,start
autocmd FileType php set omnifunc=phpcomplete#CompletePHP
autocmd FileType progress set omnifunc=syntaxcomplete#Complete
set isfname-==
" colorscheme doriath
set aw shiftwidth=4 tabstop=4 nohls expandtab
set smartcase
" Vim support file to detect file types
"
" Maintainer: Bram Moolenaar <[email protected]>
" Last Change: 2006 Aug 25
" Listen very carefully, I will say this only once
if exists("did_load_filetypes")
finish
endif
let did_load_filetypes = 1
#!/bin/bash
# Purpose :
# Author : Carl Verbiest
# vim: se ts=4 sw=4 ai:
script=$0
script_dir=${script%/*}
script=${script##*/}
suffix=$(date +%y%m%d.%H%M%S)
logfile=/tmp/$script.$suffix
@cverbiest
cverbiest / mklike
Last active August 29, 2015 14:23
Create a file/directory with same owner and permissions
#!/bin/bash
# Create a file / directory with same rights as an exiting one
typeset local
Usage() {
echo Usage $0 -r reference_file|reference_dir new_file|new_dir ...
exit 1
}
@cverbiest
cverbiest / gistpost
Last active May 2, 2020 19:02
gistpost
#!/bin/bash
# Purpose : post a file as github gist
# Author : Carl Verbiest
typeset local
script=$0
script_dir=${script%/*}
script=${script##*/}
@cverbiest
cverbiest / ocxlib_debug_list
Last active August 29, 2015 14:23
debug listing for OCX library
DEFINE VARIABLE WZ-OCXFile AS CHARACTER NO-UNDO.
DEFINE VARIABLE WZ-Alternate-OCXFile AS CHARACTER no-undo init ?.
/* Version 3 first */
WZ-OCXFile = SEARCH( "xhtml0300.wrx":U ).
WZ-Alternate-OCXFile = SEARCH( "xhtml0200.wrx":U ).
/* Definitions of handles for OCX Containers */
def temp-table T-XSEDITOR no-undo
field TXS-IDENT as char
field TXS-WIDGET AS WIDGET-HANDLE
@cverbiest
cverbiest / excel_macro_dbanalys2table
Created July 3, 2015 07:54
Excel macro to convert proutil dbanalys txt output to columns
Sub dbanalys2table()
'
' dbanalys2table Macro
'
' FieldInfo:=Array(Array(1, 1), Array(2, 1), Array(3, 1), Array(4, 1), Array(5, 1), Array(6, 1), Array(7, 1)), TrailingMinusNumbers:=True
Range("A1").Replace What:="Time stamp", Replacement:="""Time Stamp"""
Columns("A:A").Select
Selection.TextToColumns Destination:=Range("A1"), DataType:=xlDelimited, _
<html>
<head>
<script>
TestVibrate()
{
navigator.vibrate = navigator.vibrate ||
navigator.webkitVibrate ||
navigator.mozVibrate ||
navigator.msVibrate;