Skip to content

Instantly share code, notes, and snippets.

View sgnyjohn's full-sized avatar

Signey John sgnyjohn

  • 3wsistemas
  • porto alegre rs br
View GitHub Profile
@sgnyjohn
sgnyjohn / radio-play-icecast-dir-xiph-org.sh
Created April 23, 2024 13:44
BASH Icecast streaming radio player
#!/bin/bash
player=mpv
diag() {
local x="============================================================="
echo "$x
$1
$x"
}
@sgnyjohn
sgnyjohn / som-select-bluetooth-equalizador.sh
Created March 29, 2024 13:56
sh script: conecta/ativa bluetooth - ativa equalizador
#!/bin/bash
# 2024 @sgnyjohn
# conecta bluetooth - ativa equalizador
x=$(bluetoothctl devices|grep -vi "No default")
if [ "$x" = "" ]; then
echo "sem controladores..."
exit
@sgnyjohn
sgnyjohn / bugString.java
Last active October 14, 2021 16:25
openjdk11 bug
/*
openjdk 11
true 0
false 0
true 0
true 0
openjdk17
//****************************************************
// contador sonegometro,incentivometro
function contador(idDs) {
var eu = this;
var id = idDs;
var ds;
var doc = domDoc(ds);
this.vin = 0; //valor inicio
this.din = new Date(2020,0,1,0,0,0); //data valor inicio
this.vfi = 000031491940070.0; //valor fim
@sgnyjohn
sgnyjohn / testXscreenSaver-plugins-cpu.sh
Created August 4, 2019 00:55
tests cpu usage from xscreensaver plugins - Energy Star compilant ?
#!/bin/bash
aq=res.txt
echo "" >>$aq
teste() {
local n=$(basename $1)
$1 &
local p=$!
sleep 3
@sgnyjohn
sgnyjohn / se.sh
Created July 15, 2019 14:59
source code editor
#!/bin/bash
drJ=$HOME/prg/java
maxArq=10
param="$1"
if [ 0$1 -ge 1 ]; then
maxArq=$1
echo "maxArq=$maxArq"
shift
param=$1
@sgnyjohn
sgnyjohn / e.sh
Created July 15, 2019 14:05
shell editor - script
#!/bin/bash
cmd=
for i in geany gedit leafpad scite; do
cmd=$(which $i)
if [ ".$cmd" != "." ]; then
break
fi
done
@sgnyjohn
sgnyjohn / Makefile lineage 14.1 android 7.1.2 com 8gb RAM
Last active September 14, 2018 23:14
compilar lineage 14.1 android 7.1.2 com 8gb RAM # alterado linha 1132 build/core/Makefile
# Put some miscellaneous rules here
# HACK: clear LOCAL_PATH from including last build target before calling
# intermedites-dir-for
LOCAL_PATH := $(BUILD_SYSTEM)
# Pick a reasonable string to use to identify files.
ifneq "" "$(filter eng.%,$(BUILD_NUMBER))"
# BUILD_NUMBER has a timestamp in it, which means that
# it will change every time. Pick a stable value.
@sgnyjohn
sgnyjohn / detectSQLinjection.php
Created August 7, 2010 03:51
detect SQL injection - php
<?
/********************************************
detect SQL injection php
ago/2010 - classe testada
********************************************/
class detectSQLinjection {
//******************************************
function ok() {
return count($this->er)==0;
}