Skip to content

Instantly share code, notes, and snippets.

View MrXyfir's full-sized avatar

xyfir MrXyfir

View GitHub Profile

Keybase proof

I hereby claim:

  • I am MrXyfir on github.
  • I am xyfir (https://keybase.io/xyfir) on keybase.
  • I have a public key whose fingerprint is 7A15 E56B DCC1 829A A187 026B D75B 6A3C B960 A93C

To claim this, I am signing this object:

@MrXyfir
MrXyfir / GestureHandler.tsx
Last active February 2, 2021 17:15
Drag / Pinch / Rotate / Scale / Zoom / Pan with React Native and TypeScript via react-native-gesture-handler
import { StyleSheet, ViewStyle, Animated, View } from 'react-native';
import React from 'react';
import {
RotationGestureHandlerStateChangeEvent,
PinchGestureHandlerStateChangeEvent,
PanGestureHandlerStateChangeEvent,
RotationGestureHandler,
State as GestureState,
PinchGestureHandler,
PanGestureHandler,
@MrXyfir
MrXyfir / expire-all-testflight-builds.js
Last active June 2, 2020 19:19
Automatically expire all builds in TestFlight
// Quick and dirty script to expire all builds in TestFlight
// Selectors could probably be improved and simplified
// Working as of June 2nd 2020
setInterval(() => {
const doneButton = document.querySelector("body > div.tb-modal.tb-default-theme.tb-modal--nofade.tb-modal--show.tb-modal--preshow > div.ng-isolate-scope.tb-modal__box > div > div:nth-child(2) > div.tb-modal__footer > div > button");
if (doneButton) doneButton.click();
const version = document.querySelector("#train\\.id > table > tbody > tr > td:nth-child(2) > a");
if (version) version.click();
@MrXyfir
MrXyfir / self-host.md
Last active September 23, 2019 21:02

Self-hosting Ptorx

Hosting Ptorx yourself gives you a greater level of control and privacy (assuming you set everything up correctly) but it does come at a cost: it's not a simple process. If you need a self-hosted Ptorx installation you can either follow this tutorial with no support should you get stuck, or you can hire us to do it for you by sending an email to contact@xyfir.com. Some steps will be implied, or vague and generalized, so you'll be expected to know how to fill in the blanks based on your environment and requirements.

Requisites

  • Access to a domain whose DNS records you can configure.
  • A Linux server. We'll use Ubuntu.

Ptorx can run on fairly low-spec servers, but we recommend at least 1GB of RAM with 1-2GB of swap space.

@MrXyfir
MrXyfir / remotestoragejs.d.ts
Last active May 27, 2019 21:13
remotestorage.js incomplete type definitions
declare module 'remotestoragejs' {
export interface Access {
/** Claim access on a given scope with given mode. */
claim(
/**
* An access scope, such as "contacts" or "calendar" or "*".
*/
scope: string,
/**
* Access mode. Either "r" for read-only or "rw" for read/write.
@MrXyfir
MrXyfir / help.md
Last active November 12, 2020 01:00
Ptorx docs

Terminology

  • Email Aliases, alias emails, or forwarding emails
    • Email addresses created via Ptorx that typically act as a middleman for your primary emails by receiving mail and forwarding allowed mail to your primary email addresses.
  • Waterfall
    • Every alias has a waterfall that allows you to link filters, modifiers, and primary emails to it in a specific order. Each linked item is acted on in order, cascading downward like a waterfall, allowing you to redirect different mail to different primary emails based on filters and modifiers.
  • Primary Emails, real, or main emails
    • Your actual email addresses where you normally receive mail. These emails are where mail sent to your alias addresses will be redirected to. Enable Autolink to automatically link them to any new aliases you create.
  • Filters
  • Filters allow you to filter out mail (with whitelists or blacklists) before it reaches any primary emails that come after it in an alias's waterfall.