Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View calebpower's full-sized avatar

Caleb L. Power calebpower

View GitHub Profile
@calebpower
calebpower / osmoval-kicker.sh
Last active January 20, 2022 17:40
A quick script that kicks a validator back online by reconnecting it to its peers after i.e. an epoch or some other event that make sentries stall out for an extended period of time.
#!/bin/bash
# Overview
# ========
#
# This is a hack-and-slash script to re-peer the validator without rebooting it
# once sentries come back online. The following assumptions are made:
#
# - This script is used in conjunction with the validator.
# - The validator has PEX disabled and is peering only with sentries.
### Keybase proof
I hereby claim:
* I am calebpower on github.
* I am calebpower (https://keybase.io/calebpower) on keybase.
* I have a public key ASCBywwyf9HB6pW-YG6ZDgClghb4fBrVp3jBWBPk7pgluQo
To claim this, I am signing this object:
@calebpower
calebpower / BukkitSerialization.java
Created April 3, 2020 08:19 — forked from graywolf336/BukkitSerialization.java
Serialize and deserialize the player's inventory, including armor and content.
/**
* Converts the player inventory to a String array of Base64 strings. First string is the content and second string is the armor.
*
* @param playerInventory to turn into an array of strings.
* @return Array of strings: [ main content, armor content ]
* @throws IllegalStateException
*/
public static String[] playerInventoryToBase64(PlayerInventory playerInventory) throws IllegalStateException {
//get the main content part, this doesn't return the armor
String content = toBase64(playerInventory);

Keybase proof

I hereby claim:

  • I am calebpower on github.
  • I am calebpower (https://keybase.io/calebpower) on keybase.
  • I have a public key ASAThOR62dgKiP4U7VI0bd-fkLeGn0TXqBlekh2K_q8A3Ao

To claim this, I am signing this object: