Skip to content

Instantly share code, notes, and snippets.

@BrunoNZ
BrunoNZ / test_wallpaper_sizes.sh
Created June 18, 2020 20:33
A script that adds to the images files stored at "~/.cache/wallpaper" a mark containing the display ID and the resolution, both extracted from the filename. After executing the script, restart the session and then the mark appears, as the cached files are loaded.
#!/usr/bin/env bash
if ( ! command -v convert >/dev/null 2>&1 ); then
echo -e "\"Convert\" is required but it's not installed."
echo -e "Install \"imagemagick\" package and retry."
exit 1
fi
case $XDG_CURRENT_DESKTOP in
"X-Cinnamon") DIR_CACHE=~/.cache/wallpaper ;;
@BrunoNZ
BrunoNZ / ex_ponteiros.c
Last active April 19, 2020 23:05
Exemplos de usos de ponteiros, em C.
#include <stdlib.h>
#include <stdio.h>
#define T_VETOR 5
#define L_MATRIZ 2
#define C_MATRIZ 2
#define V_BASE 1
#define SEPARADOR "------------------"
// ========================================================================== //