sudo apt install -y openjdk-8-jdk
You can switch between java version with
sudo update-alternatives --config java
check with:
java --version; javac --version
// Copyright (c) 2021 oskr.nl | |
import 'package:flutter/material.dart'; | |
import 'package:flutter/cupertino.dart'; | |
import 'package:flutter/services.dart'; | |
void main() => runApp(MyApp()); | |
class MyApp extends StatelessWidget { | |
// const MyApp({Key? key}): super(key: key); |
import Hammer from "https://cdn.skypack.dev/[email protected]"; | |
var hammertime = new Hammer(document.querySelector('html'), {}); | |
hammertime.on('swiperight', e => { | |
const endPoint = e.pointers[0].pageX | |
const distance = e.distance | |
const origin = endPoint - distance | |
// swipe only within 10px from the edge | |
if (origin <= 10) | |
console.log(e) |
#!/usr/bin/bash | |
# Quickly host a static server using python3 | |
# Usage: | |
# -p <PORT> | |
# -d <DIR> the directory to serve | |
# -i <IP> the ip to bind to | |
# defaults values | |
PORT=3000 | |
DIR=. # current dir |
from flask import Flask, render_template, request | |
app = Flask(__name__) | |
@app.route('/', methods=['GET', 'POST']) | |
def hello(): | |
# respond only if the method is POST | |
# i.e. user clicked submit | |
if request.method == 'POST': | |
name=request.form.get('name', 'world') |
ffmpeg -i 1080p.mp4 -s 800x480 -c:v libx264 480p.mp4 -s 640x360 -c:v libx264 360p.mp4 -s 320x240 -c:v libx264 240p.mp4 |
from gevent import monkey; monkey.patch_all() | |
from bottle import Bottle, request, abort | |
app = Bottle() | |
@app.route('/ws') | |
def handle_ws(): | |
ws = request.environ.get('wsgi.websocket') | |
if not ws: | |
abort(400, 'Expected a WebSocket request') |
Source: https://www.reddit.com/r/firefox/comments/li2lqg/now_that_mozilla_killed_the_ssb_feature_what/
about:profiles
and create a new profile, let's name it ssb_prof
firefox --no-remote -P ssb_prof
about:support
and
a. Make sure that Profile Folder
ends with .ssb_prof
import os, time, random | |
import os.path | |
clear = lambda: os.system('cls') | |
clear() | |
def print_logo(): | |
print(f''' | |
\t _____ | |
\t / /\\ |