This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
from pydub import AudioSegment | |
import speech_recognition as sr | |
print("# Define las rutas") | |
path = '/app/audio/a00' | |
audio_file_path = f"{path}.m4a" | |
output_directory = '/app/audio/segments' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# List all pads - etherpad | |
# https://github-wiki-see.page/m/ether/etherpad-lite/wiki/How-to-list-all-pads | |
# https://etherpad.org/doc/latest/#index_http_api | |
ETHERPAD_HOST='http://127.0.0.1:9001' | |
# can be found in APIKEY.txt file in the Etherpad installation directory | |
ETHERPAD_API_KEY='...' | |
#Get api version |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"window.zoomLevel": 2, | |
"editor.columnSelection": false, | |
"workbench.colorTheme": "Arkademy", | |
"files.associations": { | |
"*.bash": "shellscript", | |
"*.jinja": "html" | |
}, | |
"explorer.confirmDelete": false, | |
"[jinja]": { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ContraseñaUltraSegura |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import datetime | |
import logging | |
logger = logging.getLogger(__name__) | |
class DatesHelper(object): | |
def convert_string_to_datetime(self, date=datetime.datetime.now()): | |
if type(date) == str or type(date) == unicode: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Ver logs del ultimo contenedor creado | |
docker ps -lq | xargs -L 1 docker logs -f | |
# Crea un alias para mostrar los logs del ultimo contenedor dev_web creado | |
alias 'dev_web'='docker container ls | grep '"'"'dev_web'"'"' | awk '"'"'{ print $1 }'"'"' ' | |
alias 'log_dev'='docker logs -f $(dev_web)' | |
#----- | |
CONTAINER_NAME=dev_web | |
docker container ls | grep "$CONTAINER_NAME" | awk "{ print $1 }" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
update ir_config_parameter set value='2021-12-12 00:00:00' where key='database.expiration_date'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT (pg_stat_file('base/'||oid ||'/PG_VERSION')).modification, datname FROM pg_database order by 1; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Backup all databases from odoo | |
#References: | |
# Backup databases: | |
# https://github.com/odoo/odoo/blob/cd9c071c9357cef14635ef094a9f14fc5431956c/addons/web/controllers/main.py#L1185 | |
# List databases | |
# https://github.com/odoo/odoo/blob/cd9c071c9357cef14635ef094a9f14fc5431956c/addons/web/controllers/main.py#L1234 | |
MASTER_PWD=password | |
BACKUP_DIR=data/backup/ | |
HOST=http://localhost:8069 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Script para organizar fotos y vídeos separandolos por la fecha en que fueron tomados | |
# fuente: https://geekland.eu/clasificar-renombrar-fotos-linux/ | |
for fil in "$@" | |
do | |
echo "*******************************" | |
# Obtiene tipo de archivo | |
FILETYPE="$(mimetype --output-format %d $fil | awk '{print $2 }')" |
NewerOlder