Skip to content

Instantly share code, notes, and snippets.

View AmmarYasserAllaithy's full-sized avatar
🔎
Open to work

Ammar Yasser Allaithy AmmarYasserAllaithy

🔎
Open to work
View GitHub Profile
@bradtraversy
bradtraversy / myscript.sh
Last active November 9, 2024 02:10
Basic Shell Scripting
#! /bin/bash
# ECHO COMMAND
# echo Hello World!
# VARIABLES
# Uppercase by convention
# Letters, numbers, underscores
NAME="Bob"
# echo "My name is $NAME"
@Jawn78
Jawn78 / Automated Posting
Created February 13, 2018 17:39
Selenium - Jsoup - Tika - Automated Web Posting
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package rexautomation;
import java.util.concurrent.TimeUnit;
import org.jsoup.Jsoup;
import org.jsoup.nodes.Document;
@tatocaster
tatocaster / RealPathUtil.java
Last active October 25, 2024 07:18
Real Path Utility class for Android, works for all API
public class RealPathUtil {
public static String getRealPath(Context context, Uri fileUri) {
String realPath;
// SDK < API11
if (Build.VERSION.SDK_INT < 11) {
realPath = RealPathUtil.getRealPathFromURI_BelowAPI11(context, fileUri);
}
// SDK >= 11 && SDK < 19
else if (Build.VERSION.SDK_INT < 19) {
@jewelsea
jewelsea / H2app.java
Created February 14, 2013 19:32
Sample for accessing a local database from JavaFX.
import java.sql.*;
import java.util.logging.*;
import javafx.application.Application;
import javafx.collections.*;
import javafx.event.ActionEvent;
import javafx.event.EventHandler;
import javafx.scene.Scene;
import javafx.scene.control.*;
import javafx.scene.layout.*;
import javafx.stage.Stage;