Skip to content

Instantly share code, notes, and snippets.

View jsmsalt's full-sized avatar
🎯
Focusing

José Morales jsmsalt

🎯
Focusing
View GitHub Profile
#! /usr/bin/env python3
#
# GlSurface example code for VLC Python bindings
# Copyright (C) 2020 Daniël van Adrichem <[email protected]>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
@daniel5gh
daniel5gh / video.py
Last active January 25, 2023 15:56
Using python vlc bindings with OpenGL texture
# Copyright (C) 2020 Daniël van Adrichem <[email protected]>
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
@AdityaRanjanSingh
AdityaRanjanSingh / mock-aws-sdk.test.js
Last active July 21, 2023 08:08
Mocking aws-sdk in jest
const AWS = require('aws-sdk');
//In the test file
const mockDynamodbGetItem = jest.fn();
const mockS3GetObject = jest.fn();
//mock aws sdk
jest.mock('aws-sdk', () => {
return {
@antfu
antfu / 📊 Weekly development breakdown
Last active November 20, 2023 10:25
📊 Weekly development breakdown
TypeScript 21 hrs 47 mins ████████████████▒░░░ 67.1%
Vue.js 6 hrs 21 mins ██████▓░░░░░░░░░░░░░ 19.6%
JSON 2 hrs 10 mins ████▒░░░░░░░░░░░░░░░ 6.7%
JavaScript 46 mins ███▒░░░░░░░░░░░░░░░░ 2.4%
@danielpereirabp
danielpereirabp / nginx-proxy
Created June 22, 2018 19:19
Nginx Proxy - SPA (Vue 2) + API/ADMIN (Laravel 5.6)
server {
listen 80;
server_name domain.com.br;
location / {
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_pass http://127.0.0.1:8181;
@kleinlennart
kleinlennart / drawer_icon.dart
Created May 24, 2018 15:01
Flutter Custom Drawer Icon (use keys)
class _HomePageState extends State<HomePage> {
final GlobalKey<ScaffoldState> _scaffoldKey = new GlobalKey<ScaffoldState>();
@override
Widget build(BuildContext context) {
return new Scaffold(
key: _scaffoldKey,
appBar: new AppBar(
title: new Text("App"),
leading: new IconButton(
@jcstr
jcstr / arch-uefi-lvm-luks.md
Last active September 10, 2021 22:48
Install an Encrypted Arch Linux
@weblancaster
weblancaster / gist:6e7f43fc02725ce747e224b0c4290906
Last active May 25, 2020 12:53
Kill all container, remove all images and stop all containers
#stop all containers:
docker kill $(docker ps -q)
#remove all containers
docker rm $(docker ps -a -q)
#remove all docker images
docker rmi $(docker images -q)
@btfak
btfak / useHexo.md
Created May 26, 2016 09:41
How to use Hexo and deploy to GitHub Pages
@SatyajeetParida
SatyajeetParida / SEO_meta_tags.txt
Last active August 17, 2019 02:24
SEO meta tags
<!-- General SEO tags -->
<meta name="author" content="Satyajeet Parida">
<meta name="description" content="">
<link rel="canonical" href="">
<!-- Social: Twitter -->
<meta name="twitter:card" content="">
<meta name="twitter:site" content="">
<meta name="twitter:creator" content="">
<meta name="twitter:title" content="">