Skip to content

Instantly share code, notes, and snippets.

View sneak's full-sized avatar

Jeffrey Paul sneak

View GitHub Profile
@bdcravens
bdcravens / apple-deadline.md
Created March 28, 2020 19:21
Updated Deadline for App Requirements and Guidelines

Dear {name},

We greatly value the worldwide developer community, and appreciate your commitment to making a difference in people’s lives through the power of technology. To accommodate developers who may need additional time to update their existing apps on the App Store, the deadline for adhering to the requirements below has been extended to June 30, 2020.

  • Apps for iPhone or iPad must be built with the iOS 13 SDK or later and use an Xcode storyboard to provide the app’s launch screen.

  • iPhone apps must support all iPhone screens and all iPad apps must support all iPad screens.

  • Apps for Apple Watch must be built with the watchOS 6 SDK or later.

@void-main
void-main / db_test.go
Last active November 22, 2019 17:38
Test Beego ORM with mocked sql driver
package db
import (
"testing"
"github.com/astaxie/beego/logs"
"github.com/astaxie/beego/orm"
"time"
@rakd
rakd / template.go
Created December 6, 2017 05:20
template inheritance for echo/golang
package main
import (
"fmt"
"html/template"
"io"
"log"
"os"
"path/filepath"
"strings"
@ValdikSS
ValdikSS / huawei-e5885-backup.md
Last active October 27, 2023 18:32
How to backup current firmware on Huawei E5885

Huawei E5885 current firmware backup manual.

  1. Download modified usbloader, which will copy proper busybox into /system/busybox and enable telnetd on your device (will add additional line into /system/autorun.sh). Use it only on E5885, not on other device!
  2. Load it using balong-usbdload. Refer to this disassembling manual.
  3. After loading, wait about one minute, disconnect device from the computer and power off the device holding power button for ~15 seconds.
  4. Insert MicroSD card to the device and power it on.
  5. telnet 192.168.8.1 2323
/system/busybox sh
@lummie
lummie / enum.go
Last active June 16, 2024 16:19
Golang Enum pattern that can be serialized to json
package enum_example
import (
"bytes"
"encoding/json"
)
// TaskState represents the state of task, moving through Created, Running then Finished or Errorred
type TaskState int
@lene
lene / socat_socks_proxy.sh
Last active October 7, 2023 07:52
Using tor as SOCKS proxy with SOCAT
socat TCP-LISTEN:<localport> SOCKS4A:localhost:<host>:<remoteport>,socksport=9050
# for example, to ssh into secret.shell.server.org via tor, do:
$ socat TCP-LISTEN:22222 SOCKS4A:localhost:secret.shell.server.org:22,socksport=9050 &
$ ssh localhost -p 22222
@tchap
tchap / steemd_rpc_example.go
Last active August 22, 2016 16:44
Accessing steemd RPC programatically using Golang
package main
import (
"flag"
"fmt"
"log"
"net/rpc/jsonrpc"
"time"
"golang.org/x/net/websocket"
@montanaflynn
montanaflynn / poker.go
Last active June 2, 2024 03:17
Generate a deck of cards, shuffle it and then deal them out in Golang
package main
import (
"fmt"
"math/rand"
"os"
"time"
)
// Card holds the card suits and types in the deck
@izderadicka
izderadicka / megaback.sh
Last active February 7, 2022 04:53
backup script for megatools
#!/bin/bash
BACKUP_DIR="/Root/Backup/"
PIECE_SIZE=10M
ACTION=store
trap "exit 2" SIGINT
if [[ $1 =~ -h|--help ]]; then
@reiki4040
reiki4040 / signal.go
Created October 2, 2014 14:38
signal handling example for golang
package main
import (
"fmt"
"os"
"os/signal"
"syscall"
)
func main() {