Skip to content

Instantly share code, notes, and snippets.

@vbuterin2
vbuterin2 / xfreerdp.sh
Created July 15, 2021 20:45
xfreerdp cookbook
xfreerdp \
+clipboard \
+home-drive \
+unmap-buttons \
+async-channels \
+auto-reconnect \
-encryption \
/sound:rate:44100,channel:2 \
/kbd:0x00000409 \
/bpp:16 \
@vbuterin2
vbuterin2 / xpath_soup.py
Created June 12, 2021 07:01 — forked from ergoithz/xpath_soup.py
Generate unique XPATH for BeautifulSoup element
#!/usr/bin/python
# -*- coding: utf-8 -*-
def xpath_soup(element):
# type: (typing.Union[bs4.element.Tag, bs4.element.NavigableString]) -> str
"""
Generate xpath from BeautifulSoup4 element.
:param element: BeautifulSoup4 element.
:type element: bs4.element.Tag or bs4.element.NavigableString
@vbuterin2
vbuterin2 / flutter.sh
Created May 15, 2021 02:34
install flutter on ubuntu
sudo vim $HOME/.bashrc
sudo vim $HOME/.zshrc
echo $HOME/development/flutter/bin
$HOME/development/flutter/bin
export PATH="$PATH:"
@vbuterin2
vbuterin2 / readme.md
Last active May 11, 2021 11:43
Dart Installation on Ubuntu LTS
 sudo apt-get install -y apt-transport-https
 sudo sh -c 'wget -qO- https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add -'
 sudo sh -c 'wget -qO- https://storage.googleapis.com/download.dartlang.org/linux/debian/dart_stable.list > /etc/apt/sources.list.d/dart_stable.list'
 sudo apt-get -y update
 sudo apt-get install -y dart
@vbuterin2
vbuterin2 / crd.sh
Last active May 1, 2021 08:57
Deploy chrome-remote-desktop
#!/bin/bash -x
#
# This script should only be used in ubuntu
function install_visual_studio_code {
sudo snap install code --classic
}
function install_oh_my_zsh {
@vbuterin2
vbuterin2 / delete-likes-from-twitter.md
Created October 19, 2020 08:01 — forked from aymericbeaumet/delete-likes-from-twitter.md
[Recipe] Delete all your likes/favorites from Twitter

Ever wanted to delete all your likes/favorites from Twitter but only found broken/expensive tools? You are in the right place.

  1. Go to: https://twitter.com/{username}/likes
  2. Open the console and run the following JavaScript code:
setInterval(() => {
  for (const d of document.querySelectorAll('div[data-testid="unlike"]')) {
    d.click()
 }
#include <iostream>
#include <vector>
int main(void) {
// Create and init a vector
// 1. vector<int> variable; variable.push_back()
std::vector<int> lucky_numbers;
lucky_numbers.push_back(1);
lucky_numbers.push_back(100);
// vector::push_back
#include <iostream>
#include <vector>
int main()
{
vector<int> v1;
const vector<int> v2;
// vector::push_back
#include <iostream>
#include <vector>
int main()
{
std::vector<int> my_vector;
int my_int;
std::cout << "Please enter some integer (enter 0 to end): \n";
#include <iostream>
#include <iostream>
using namespace std;
int main(void)
{
// Initialize 2D array
char colour[4][10] = {"blue", "red", "organce", "yellow"};