Skip to content

Instantly share code, notes, and snippets.

View xoxwgys56's full-sized avatar
🚶
As it was

Yoooda xoxwgys56

🚶
As it was
View GitHub Profile
@xoxwgys56
xoxwgys56 / jetbrain-ide-alias.sh
Last active December 7, 2021 01:15
Run Jetbrains IDE on terminal
# jetbrain
# tested on IOS
alias webstorm="foo() {open -na 'WebStorm.app' --args '$@'}; foo"
alias wstorm="foo() {open -na 'WebStorm.app' --args '$@'}; foo"
alias dataspell="foo() {open -na 'DataSpell.app' --args '$@'}; foo"
alias dspell="foo() {open -na 'DataSpell.app' --args '$@'}; foo"
alias rider="foo() {open -na 'Rider.app' --args '$@'}; foo"
alias pycharm="foo() {open -na 'Pycharm.app' --args '$@'}; foo"
@xoxwgys56
xoxwgys56 / ebook-capture.applescript
Created December 2, 2021 01:14
ebook screen capture
# init for loop
set idx to 0 as number
set maxRange to 110 as number
# init environment value
set basePath to "~/local/screenshots"
set srcPath to basePath & "/temp" as string
set destPath to basePath & "/result" as string
do shell script "mkdir -p " & srcPath
do shell script "mkdir -p " & destPath
set applicationName to "AppName"
@xoxwgys56
xoxwgys56 / UnityPostRequestSample.cs
Last active October 25, 2021 02:12
UnityPostRequestSample
using System.Collections;
using UnityEngine;
using UnityEngine.Networking;
using Newtonsoft.Json;
/// <summary>
/// This sample code work properly on Unity2020.3 <br/>
/// </summary>
public class UnityPostRequestSample : MonoBehaviour {
@xoxwgys56
xoxwgys56 / reinstall.sh
Created August 5, 2021 00:51
Encounter error about "WorkerError: failed to process image"
#! /bin/bash
# copied from https://github.com/gatsbyjs/gatsby/issues/21515#issuecomment-588416624
rm -rf node_modules
rm package-lock.json
npm cache clear --force
npm install
@xoxwgys56
xoxwgys56 / myscript.sh
Created August 5, 2021 00:50 — forked from bradtraversy/myscript.sh
Basic Shell Scripting
#! /bin/bash
# ECHO COMMAND
# echo Hello World!
# VARIABLES
# Uppercase by convention
# Letters, numbers, underscores
NAME="Bob"
# echo "My name is $NAME"
@xoxwgys56
xoxwgys56 / myscript.sh
Created August 5, 2021 00:50 — forked from bradtraversy/myscript.sh
Basic Shell Scripting
#! /bin/bash
# ECHO COMMAND
# echo Hello World!
# VARIABLES
# Uppercase by convention
# Letters, numbers, underscores
NAME="Bob"
# echo "My name is $NAME"
@xoxwgys56
xoxwgys56 / mangling_example.py
Last active August 4, 2021 06:04
python name mangling example with class
"""
Below value called `private` or `protected` is not accredited expression.
I choose those expression for easy to understand scope.
"""
class MyClass:
__private_value = 'private'
_protected_value = 'protected'
public_value = 'public'
@xoxwgys56
xoxwgys56 / regex-with-position.py
Created August 4, 2021 05:48
find digit group from text using re
import re
"""
find digit group from text
"""
def print_match(m):
print('\t',{
'start':m.start(),
'group': m.group(),
@xoxwgys56
xoxwgys56 / paragraph.py
Last active August 4, 2021 05:32
get paragraph from string
"""
This gist inspired from below repository. and suppose input type is plain string.
https://github.com/nirajdpandey/passage-retrieval-chatbot
"""
from typing import List, Callable
def paragraphs(file: str, is_separator: Callable = None):
"""paragraph generator"""
@xoxwgys56
xoxwgys56 / gist:ccfdb25a410e48f208fc9c2f9f140c9b
Created July 26, 2021 04:02 — forked from asabaylus/gist:3071099
Github Markdown Heading Anchors

Anchors in Markdown

To create an anchor to a heading in github flavored markdown. Add - characters between each word in the heading and wrap the value in parens (#some-markdown-heading) so your link should look like so:

[create an anchor](#anchors-in-markdown)