Skip to content

Instantly share code, notes, and snippets.

@paucoma
paucoma / pdftoolsgems.md
Last active December 31, 2024 16:54
PDF tools hidden gems

qpdf ** --decrypt --remove-restrictions ** <-- Usefull when a pdf is digitally signed to be able to mark it.

@paucoma
paucoma / rclone_synology_pcloud_setup.md
Last active December 31, 2024 00:19
Rclone Synology backup / sync with pCloud

Rclone Synology backup / sync with pCloud

// Background: I initially had a local server a synology DS215j
// Resources: 
//   - [ravem/synology-pcloud-and-rclone](https://github.com/ravem/synology-pcloud-and-rclone?tab=readme-ov-file)
//   - [Part 3. How To Backup Synology NAS to pCloud With Rclone](https://recoverit.wondershare.com/backup-files/synology-pcloud.html)
// Failed Alternatives : 
//   - I attempted to use the Synology package "Cloud Sync" with WebDaV as described [in this post](https://community.synology.com/enu/forum/1/post/186320) 
//      + The WebDAV Accesses {pCloud (US): https://webdav.pcloud.com ; pCloud (EU): https://ewebdav.pcloud.com}
//        * The username/password would not work and therefore I did not progress on this front.
@paucoma
paucoma / WA-VidShare-iPhoneCompatible.md
Created October 7, 2024 18:29
Video sent via WhatsApp from Android unplayable on iOS iPhone

While sharing videos to a WhatsApp group chat from my phone, a Google Pixel 4a, some participants could not view the video.. They only could hear the contents of the video.

After finding several threads with no resolution and someone contributing a video which did work for the iPhone users I started investigating. https://www.reddit.com/r/whatsapp/comments/1e4q38c/video_sent_from_android_unplayable_on_ios_and_web/ https://support.google.com/pixelphone/thread/290866570/google-4a-videos-on-whatsapp?hl=en https://support.google.com/pixelphone/thread/290626638/since-july-2024-video-sent-on-whatsapp-from-all-pixel-models-cannot-be-viewed-on-iphone?hl=en

I found that there were several differences, one of which was the colorspace encoding. Investigated a bit via ffmpeg and bothering a couple friends which use iPhones I found a workaround.

https://ffmpeg.org/ffmpeg-filters.html#scale-1

@paucoma
paucoma / net-details-Wallapop
Last active August 7, 2024 06:35
Wallapop Chat service network port
I was having the chat messages from the App Wallapop, blocked whenever connected to my local wifi network.
I would disconnect from the wifi and connected to the cell service it would work.
Searching online the Keywords "Wallapop network port chat" gave no useful result.
Searching for App network usage traffic keywords landed me to the following Q/A :
https://android.stackexchange.com/questions/203868/how-to-view-network-traffic-requested-by-a-specific-app
This led me to test the following OpenSource App [PCAPdroid - network monitor](https://play.google.com/store/apps/details?id=com.emanuelef.remote_capture), https://github.com/emanuele-f/PCAPdroid
This creates a local VPN and views the App requests.
@paucoma
paucoma / ICS Import.gs
Last active October 7, 2023 22:33 — forked from tomjaimz/ICS Import.gs
Google App Script code to import events from a Calendar (.ics) file into Google Sheets.
function onOpen() {
SpreadsheetApp.getUi()
.createAddonMenu()
.addItem('Upload', 'upload')
.addToUi();
}
function upload() {
const hs = HtmlService.createHtmlOutput(
'<form><input type="file" name="file" onchange="var reader = new FileReader(); reader.onloadend = (e) => google.script.run.withSuccessHandler(google.script.host.close).importICS(e.target.result); reader.readAsText(this.parentNode.file.files[0]);"></form>'
@paucoma
paucoma / sub2vcd.py
Created July 28, 2022 18:15
Python Script to convert Flipper RAW .sub file to a Basic VCD Value Change Dump format
#!/usr/bin/env python
# Flipper RAW .sub format
#
# Having a look at some of the code in lib/subghz/protocols/raw.c
# - Decoded data is stored as a line starting with the text "Raw_Data: " followed by space delimited integers.
# - Each line stores a maximum number of integers limited to SUBGHZ_DOWNLOAD_MAX_SIZE ,defined as 512. Then a new line is written.
# - The sign of each integer represents a decoded signal logic level, positive / negative , logic level 1 / 0
# - The absolute value of each integer represents the signal level duration. I am guessing this is in micro-seconds
@paucoma
paucoma / TLEN.LSP
Last active December 5, 2024 11:03
Autocad Lisp Script : TLEN.lsp (Total LENgth of selected objects)
;|
Source:
- [Forum Conversation](https://forums.autodesk.com/t5/autocad-forum/how-to-calculate-the-total-length-of-multiple-lines/td-p/5120514)
- [Link with actual code](http://web.archive.org/web/20201112011622/http://www.turvill.com/t2/free_stuff/tlen.lsp)
Instructions:
- Simply copy/paste (CTRL+V) ALL the code, (defun... ...), into your command line and press Enter.
- type TLEN into the command line and follow the command prompt (select the objects)
|;
@paucoma
paucoma / toPDF.sh
Last active February 23, 2021 17:06
Nemo Filemanager script to convert image to pdf with img2pdf with single or multiple file arguments
#!/bin/bash
# Description: This Nemo script uses img2pdf with single or multiple file arguments.
# script location: ~/.local/share/nemo/scripts/
# Resources:
# [img2pdf Homepage](https://gitlab.mister-muffin.de/josch/img2pdf)
# [img2pdf mirror on github](https://github.com/josch/img2pdf)
# Tags: img2pdf nemo-filemanager nemo-script
#arguments passed to img2pdf
myoptions="--pagesize A4 --fit shrink"
@paucoma
paucoma / Contract Killer 3.md
Created March 3, 2020 12:58
The latest version of my ‘killer contract’ for web designers and developers

Contract Killer

The popular open-source contract for web professionals by Stuff & Nonsense

  • Originally published: 23rd December 2008
  • Revised date: March 15th 2016
  • Original post

@paucoma
paucoma / TinyTaskCfgMod.c
Created November 18, 2018 22:55
Tiny Task Configuration File Modifier
/*
Deciphering TinyTask Recording Format after a bit of trial and error I found and used the following
*/
#include<stdio.h>
/* Our structure
- 0002 0000 7906 0000 4501 0000 dd0a 9400 7607 0b00
- 20 bytes in length
- interpreted as shorts, when we read it with fread, bytes get reordered
- 0200 0000 0679 0000 0145 0000 0add 0094 0776 000b
*/