Skip to content

Instantly share code, notes, and snippets.

Anh Tu Nguyen xgenvn

Block or report user

Report or block xgenvn

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
xgenvn /
Created Aug 13, 2019
Skill Competence

Basic Knowledge

You have a common knowledge or an understanding of basic techniques and concepts.

  • Focus on learning.

Limited experience

You have the level of experience gained in a classroom and/or experimental scenarios or as a trainee on-the-job. You are expected to need help when performing this skill.

View gradle-cheatsheet.gradle
// imports a couple of java tasks
apply plugin: "java"
// List available tasks in the shell
> gradle tasks
// A Closure that configures the sourceSets Task
// Sets the main folder as Source folder (where the compiler is looking up the .java files)
sourceSets { "src/main"
xgenvn / Install PyQt5 on Ubuntu with python3 .md
Created Aug 1, 2019 — forked from ujjwal96/Install PyQt5 on Ubuntu with python3 .md
Install PyQt5 on Ubuntu with python3. Steps to set up PyQt5 (ubuntu). With python code generation
View Install PyQt5 on Ubuntu with python3 .md


pip3 install --user pyqt5  
sudo apt-get install python3-pyqt5  
sudo apt-get install pyqt5-dev-tools
sudo apt-get install qttools5-dev-tools

Configuring to run from terminal

xgenvn / docker-compose.yml
Created Jul 30, 2019 — forked from ninformations/docker-compose.yml
Docker compose file to start a local arangodb cluster
View docker-compose.yml
version: '2'
image: arangodb/arangodb
command: --server.jwt-secret=openSesameJWT --database.password openSesame --server.endpoint tcp:// --agency.activate true --agency.size 1 --agency.supervision true
image: arangodb/arangodb
sudo add-apt-repository ppa:linuxuprising/java
sudo apt update
sudo apt install oracle-java12-installer
xgenvn /
Created Apr 27, 2019 — forked from sanketsudake/
Fission with Minikube and Helm
# Install virtualbox
sudo apt install virtualbox
# Install Kubectl
curl -LO$(curl -s && chmod +x kubectl && sudo mv kubectl /usr/local/bin
# Install Minikube
curl -Lo minikube && chmod +x minikube && sudo mv minikube /usr/local/bin/
# Launch Minikube
minikube start
xgenvn /
Last active Apr 10, 2019
AttachedProperty vs Behavior

Attached Property

public static class FocusOnLoad
    public static bool GetCanFocusOnLoad(DependencyObject obj)
        return (bool)obj.GetValue(CanFocusOnLoadProperty);
xgenvn / ffmpeg-compress-mp4
Created Apr 2, 2019 — forked from lukehedger/ffmpeg-compress-mp4
Compress mp4 using FFMPEG
View ffmpeg-compress-mp4
$ ffmpeg -i input.mp4 -vcodec h264 -acodec mp2 output.mp4

Async Await Best Practices Cheat Sheet

Summary of Asynchronous Programming Guidelines

Name Description Exceptions
Avoid async void Prefer async Task methods over async void methods Event handlers
Async all the way Don't mix blocking and async code Console main method
Configure context Use ConfigureAwait(false) when you can Methods that require con­text
xgenvn /
Created Mar 16, 2019 — forked from tilfin/
Face detect and crop by using OpenCV
import cv2
import sys
import os
class FaceCropper(object):
CASCADE_PATH = "data/haarcascades/haarcascade_frontalface_default.xml"
def __init__(self):
self.face_cascade = cv2.CascadeClassifier(self.CASCADE_PATH)
You can’t perform that action at this time.