Skip to content

Instantly share code, notes, and snippets.

View SnowyPainter's full-sized avatar
๐ŸŽฏ
Focusing

Minwoo Yu SnowyPainter

๐ŸŽฏ
Focusing
View GitHub Profile
using System;
using System.Reflection;
using Xamarin.Forms;
using Xamarin.Forms.Xaml;
namespace HeVibrates
{
[ContentProperty (nameof(Source))]
class ImageResourceExtension:IMarkupExtension
{
App.Current.Properties.Add("key", value);
await App.Current.SavePropertiesAsync();
import 'dart:io';
import 'dart:convert';
Future main() async {
var server = await HttpServer.bind(
InternetAddress.loopbackIPv4,
3000,
);
print('Listening on localhost:${server.port}');
@SnowyPainter
SnowyPainter / PlayerController.cs
Created January 2, 2021 08:02
This will perfectly work with your FPS player
using UnityEngine;
public class PlayerController : MonoBehaviour
{
const float walkSpeed = 5.0f, runSpeed=8.0f;
float yRot, xRot;
float rotationSpeed = 7f;
float speed;
[SerializeField]
Camera cam;
@SnowyPainter
SnowyPainter / start_flameshot.sh
Created January 1, 2021 12:08
Open flameshot
flameshot gui
@SnowyPainter
SnowyPainter / set.txt
Last active November 14, 2020 14:28
Android Studio Setting up for Ubuntu
source ~/.bash_profile
grep kvm /etc/group
chown $USER /dev/kvm
flutter pub get
@SnowyPainter
SnowyPainter / ListsExtension.cs
Created November 4, 2020 13:31
In short, all of the List<inheritances> of INTERFACE can be called, It actually works just like Stack.Pop
public static class ListsExtension
{
public static T Pop<T>(this List<T> clist, int index) where T : INTERFACE
{
var c = clist[index];
cargos.RemoveAt(index);
return c;
}
}
public static class Path {
private bool isValidPath(string path)
{
if (path.Length < 3 ||
!new Regex(@"^[a-zA-Z]:\\$").IsMatch(path.Substring(0, 3)) ||
!DriveInfo.GetDrives().Select(drive => drive.Name).Contains(path.Substring(0, 3)) ||
new Regex("[" + Regex.Escape(new string(Path.GetInvalidPathChars()) + @":/?*" + "\"") + "]").IsMatch(path.Substring(3, path.Length - 3)) ||
path[path.Length - 1] == '.')
return false;
@SnowyPainter
SnowyPainter / LICENSE
Created September 20, 2020 17:39
์ €์ž‘๋ฌผ ๋ผ์ด์„ ์Šค ํƒฌํ”Œ๋ฆฟ License template for a Github organization
๋ณธ github.com์˜ repositorie ์†, ํ”„๋กœ์ ํŠธ ์ œ์•ˆ์„œ ๋“ฑ๊ณผ ๊ฐ™์€ ๋ชจ๋“  ๋ฌธ์„œ, ์‚ฌ์ง„ ๋“ฑ์€ โ€˜ORGANIZATION_NAMEโ€™ github organization์˜ ์†Œ์œ  ์ฐฝ์ž‘๋ฌผ์ž…๋‹ˆ๋‹ค.
์œ„ ์ €์ž‘๋ฌผ ๋“ฑ์€ ์•„๋ž˜์™€ ๊ฐ™์€ CCL์„ ๋”ฐ๋ฆ…๋‹ˆ๋‹ค.
CC BY NC ND
์ €์ž‘๋ฌผ์„ ์‚ฌ์šฉํ• ๋•, ์ €์ž‘๊ถŒ์ž(์ดํ•˜ ORGANIZATION_NAME)๋ฅผ ํ‘œ์‹œํ•ด์•ผํ•˜๋ฉฐ,
๊ทธ ๋ชฉ์ ์€ ๋น„์˜๋ฆฌ์—ฌ์•ผ ํ•ฉ๋‹ˆ๋‹ค. ๋˜ํ•œ ์ €์ž‘๋ฌผ์˜ ๋‚ด์šฉ์„ ๋ณ€๊ฒฝ ํ•  ์ˆ˜ ์—†์Šต๋‹ˆ๋‹ค.
ํ•˜์ง€๋งŒ ์ถœ์ฒ˜์™€ ์ €์ž‘๊ถŒ์ž๋ฅผ ๋ช…์‹œ ํ•œ๋‹ค๋ฉด ์‚ฌ์šฉ ํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.
@SnowyPainter
SnowyPainter / setgopath.sh
Created September 13, 2020 17:33
Set gopath
export GOPATH=Address ex) $HOME/MyProject
export PATH=$PATH:$GOROOT/bin:$GOPATH/bin