A fork of andytuba RES settings backup script
Originally [andytuba]{https://gist.github.com/andytuba) created a script to convert Chrome RES backups and concert them to FireFox RES backups. I needed to go the other direction so I started this.
A fork of andytuba RES settings backup script
Originally [andytuba]{https://gist.github.com/andytuba) created a script to convert Chrome RES backups and concert them to FireFox RES backups. I needed to go the other direction so I started this.
#!/usr/bin/env python | |
import asyncio | |
import websockets | |
import binascii | |
import ujson as json | |
method_map = { | |
'6d01': 'Set Name', | |
'6d02': 'Post Memo', |
// import_json_appsscript.js | |
// https://gist.github.com/allenyllee/c764c86ed722417948fc256b7a5077c4 | |
// | |
// Changelog: | |
// (Jul. 16 2018) tag: allenyllee-20180716 | |
// 1. Fixed the issue "If you try to query /arrayA[k]/arrayB[n]/arrayC[m]/.../member, you will always get /arrayA[k]/arrayB[k]/arrayC[k]/.../member." | |
// (Nov. 30 2017) tag: allenyllee-20171130 | |
// 1. Add the ability to query array elements by using xpath like "/array[n]/member" where "n" is array index | |
// 2. Fixed Issue: when the path and the rule partially matched but not under the same xpath, it will still print that value under that xpath. |
trait Field { | |
type ValueType; | |
} | |
use std::marker::PhantomData as Marker; | |
struct X<T>(Marker<T>); | |
struct Y<T>(Marker<T>); | |
struct Z<T>(Marker<T>); |
# ---------------------------------------------------------------------------------- | |
# r u s t f m t - C O N F I G | |
# ================================================================================== | |
# | |
# Version: 0.7.1 | |
# Author : Robbepop <[email protected]> | |
# | |
# A predefined .rustfmt.toml file with all configuration options and their | |
# associated description, possible values and default values for use in other | |
# projects. |
//! this script recreates the book | |
//! "It's not a sin: An Introduction to the Trigonometric Values of Standard Functions" | |
extern crate rand; // 0.8.4; | |
use rand::prelude::*; | |
const DEGREES_RANGE: std::ops::RangeInclusive<i16> = -2000..=2000; | |
const NUMBER_QUESTIONS: i16 = 20; // questions per function. 250 in the book | |
fn main() { | |
let mut rng = thread_rng(); | |
let functions: Vec<(&str, fn(f64) -> f64)> = | |
vec![("sin", f64::sin), ("cos", f64::cos), ("tan", f64::tan)]; |
This is a compiled list of falsehoods programmers tend to believe about working with time.
Don't re-invent a date time library yourself. If you think you understand everything about time, you're probably doing it wrong.