Skip to content

Instantly share code, notes, and snippets.

View vegetaz's full-sized avatar
🏠
Working from home

Nguyễn Văn Vận vegetaz

🏠
Working from home
View GitHub Profile
@vegetaz
vegetaz / theNextCuteVOZ.js
Last active March 9, 2022 07:37
Script này sử dụng trong Tampermonkey để tối ưu hóa lại giao diện của voz.vn
// ==UserScript==
// @name theNextCuteVOZ
// @namespace theNextCuteVOZ
// @description Utilize for vOz. Lưu ý rằng mình không phải là idmresettrial, mình chỉ sử dụng code của thím ấy!
// @author idmresettrial
// @homepage voz.vn
// @run-at document-start
// @version 0.20201028020217
// ==/UserScript==
(function() {var css = "";
@vegetaz
vegetaz / QuickSort.java
Created December 17, 2019 09:03
Quick Sort
public class QuickSort {
public static void main(String[] args) {
int[] x = {6, 2, 3, 4, 5, 9, 1};
printArray(x);
int left = 0;
int right = x.length - 1;
quickSort(x, left, right);
printArray(x);
@vegetaz
vegetaz / setJAVA_HOME.cmd
Created May 12, 2019 11:46
bat/cmd file to set java home path
@echo off
echo Setting JAVA_HOME
setx -m JAVA_HOME "C:\Program Files\Java\jdk1.8.0_212"
echo JAVA_HOME: %JAVA_HOME%
echo setting PATH
setx -m PATH "%Path%;%JAVA_HOME%\bin"
echo PATH: %PATH%
echo Display java version
java -version
pause
@vegetaz
vegetaz / Convert-Encoding.ps1
Created April 19, 2019 06:08 — forked from jamesfdickinson/Convert-Encoding.ps1
Convert all files to UTF-8 using powershell
Param (
[Parameter(Mandatory=$True)][String]$SourcePath
)
Get-ChildItem $SourcePath\* -recurse -Include *.json,*.html,*.xml,*.js,*.txt,*.css | ForEach-Object {
$content = $_ | Get-Content
Set-Content -PassThru $_.Fullname $content -Encoding UTF8 -Force}
@vegetaz
vegetaz / Visual C++.sublime-build
Created January 17, 2017 23:08 — forked from mikhdm/Visual C++.sublime-build
Visual C++ build system for sublime text to exec and compile .c and .cpp files from Subime Text editor.
{
"cmd": ["vcvars32.bat", "&", "cl", "/EHsc", "${file}"],
"file_regex": "^(..[^:]*):([0-9]+):?([0-9]+)?:? (.*)$",
"working_dir": "${file_path}",
"selector": "source.c, source.cpp, source.c++",
// By default cl is not in your PATH, so add it to your path (preferably)
// or uncomment "path" and check that it has correct value
//"path": "path:/to/folder/where/cl.exe/located",
// this also will set path for vcvars32.bat
"shell": true, // Without this sublime has hard times to parse "&" in out command line