Skip to content

Instantly share code, notes, and snippets.

View andarilhoz's full-sized avatar
😀
Now it goes!

Magno Gouveia andarilhoz

😀
Now it goes!
View GitHub Profile
@andarilhoz
andarilhoz / shutdownServer.sh
Last active January 27, 2024 17:57
Desligar o servidor automaticamente quando não tiverem jogadores
#!/bin/bash
cd /home/ubuntu/palworld
# Execute o comando para obter a lista de jogadores e capturar possíveis erros
OUTPUT=$(docker-compose run --rm rcon ShowPlayers 2>&1)
# Filtra linhas indesejadas
CLEANED_OUTPUT=$(echo "$OUTPUT" | grep -v "Creating palworld_rcon_run")
cache:
key: "$CI_BUILD_REF_NAME node:8-alpine"
paths:
- node_modules/
stages:
- build
- release
- deploy
@andarilhoz
andarilhoz / sp
Created October 10, 2016 18:13 — forked from duncan-bayne/sp
sp is a command-line client for Spotify's dbus interface. Play, pause, skip and search tracks from the comfort of your command line.
#!/bin/bash
#
# This is sp, the command-line Spotify controller. It talks to a running
# instance of the Spotify Linux client over dbus, providing an interface not
# unlike mpc.
#
# Put differently, it allows you to control Spotify without leaving the comfort
# of your command line, and without a custom client or Premium subscription.
#