Skip to content

Instantly share code, notes, and snippets.

View Obooman's full-sized avatar

Oboo Cheng Obooman

View GitHub Profile
@Obooman
Obooman / profile.json
Last active October 22, 2020 04:44
mac-like microsoft terminal profile with ubuntu as default.
// This file was initially generated by Windows Terminal 1.3.2651.0
// It should still be usable in newer versions, but newer versions might have additional
// settings, help text, or changes that you will not see unless you clear this file
// and let us generate a new one for you.
// To view the default settings, hold "alt" while clicking on the "Settings" button.
// For documentation on these settings, see: https://aka.ms/terminal-documentation
{
"$schema": "https://aka.ms/terminal-profiles-schema",
"defaultProfile": "{61c54bbd-c2c6-5271-96e7-009a87ff45bf}",
"initialRows": 20,
@Obooman
Obooman / inkscape stroke to path script.sh
Created July 1, 2019 13:59
Bash use inkscape turn stroked svg line into filled sharps.
inkscape -f /Users/oboo_chin/Downloads/feather/align-left.svg --verb="EditSelectAll" --verb="EditSelectSameStrokeStyle" --verb="StrokeToPath" --verb="SelectionUnion" --verb="FileSave" --verb="FileQuit"
@Obooman
Obooman / default.less
Created December 25, 2018 03:07
bimops default style.
/* stylelint-disable at-rule-empty-line-before,at-rule-name-space-after,at-rule-no-unknown */
@import '../color/colors';
// The prefix to use on all css classes from ant.
@ant-prefix : ant;
// -------- Colors -----------
@primary-color : @ops-blue;
@info-color : @blue-6;
@success-color : @green-6;
echo -e "\e[34
◀▶\e[33m ╔╗ \e[33m┬─┐\e[92m┌─┐\e[96m┌─┐\e[96m┬┌─\e[154┌─┐\e[25m┌┐┌
◀▶\e[31m ╠╩╗\e[31m├┬┘\e[93m├─┤\e[93m│ \e[92m├┴┐\e[34├┤\e[96m │││
◀▶ \e[31m╚═╝\e[33m┴└─\e[96m┴ ┴\e[99m└─┘\e[93m┴ ┴\e[34└─┘\e[35m┘└┘
\e[92mhttps://bracken.io
\e[92mhttps://bra.ke.qq.com
"
@Obooman
Obooman / load.m
Created December 10, 2017 14:44
change rn load source url
// Run from locally running dev server
jsCodeLocation = [NSURL URLWithString:@"http://localhost:8081/index.ios.bundle"];
// Run on device with code coming from dev server on PC (change the IP to your PCs IP)
// jsCodeLocation = [NSURL URLWithString:@"http://192.168.1.168:8081/index.ios.bundle"];
// For production load from pre-bundled file on disk. To re-generate the static bundle, run
// $ curl http://localhost:8081/index.ios.bundle -o main.jsbundle
// jsCodeLocation = [[NSBundle mainBundle] URLForResource:@"main" withExtension:@"jsbundle"];
@Obooman
Obooman / terminal FBI warning.sh
Created November 13, 2017 08:07
display FBI warning login scene.
echo -e "
\e[41m\e[1m FBI \e[21mWARNING \e[49m
Federal Law probides servere civil and criminal penaltaties for
the unauthorized reproduction, distribution, or exhibition of
copyrighted mothion pictures(Title 17,United States Code,
Sections 501 and 508).The Federal Bureau of Investigation
@Obooman
Obooman / integrate react-native to swift project.md
Created November 6, 2017 06:25 — forked from boopathi/README.md
Creating a Swift-ReactNative project

Settings

  1. Create a project in XCode with the default settings
    • iOS > Application > Single View Application
    • Language: Swift
  2. Under project General settings, add ReactKit to Linked Framework and Libraries
    • + > Add Other... and choose /path/to/react-native/ReactKit/ReactKit.xcodeproj
  3. Now ReactKit would have been imported. Link it by choosing it from the list.
    • + > lib.ReactKit.a
  4. Under project Build Settings,
@Obooman
Obooman / App.js
Created October 5, 2017 03:03
file for StackOverflow answer.
import React, { Component } from 'react';
import { Text, View, StyleSheet,Image,TouchableOpacity } from 'react-native';
export default class App extends Component {
render() {
return (
<View style={styles.container}>
<Image
source={{ uri:"https://preview.ibb.co/e883Jw/2010_brown_bear.jpg" }}
style={ styles.imageWrapper }>
@Obooman
Obooman / cloudSettings
Last active January 25, 2018 09:40
Demo code for bug react-navigation#2569
{"lastUpload":"2018-01-25T09:40:08.610Z","extensionVersion":"v2.8.7"}
class AutoExpandingTextInput extends React.Component {
state: any;
constructor(props) {
super(props);
this.state = {text: '', height: 0};
}
render() {
return (
<TextInput