Skip to content

Instantly share code, notes, and snippets.

View arn-ob's full-sized avatar
☠️
__worker__

Arnob arn-ob

☠️
__worker__
View GitHub Profile
@arn-ob
arn-ob / Get-MP3MetaData.ps1
Created October 15, 2016 16:29 — forked from PrateekKumarSingh/Get-MP3MetaData.ps1
Get MetaData from a .MP3 or .MP4 file
Function Get-MP3MetaData
{
[CmdletBinding()]
[Alias()]
[OutputType([Psobject])]
Param
(
[String] [Parameter(Mandatory=$true, ValueFromPipeline=$true)] $Directory
)
@arn-ob
arn-ob / gist:cca5db64243a157a3ea552ef06b1e593
Created December 3, 2016 05:40 — forked from alishutc/gist:a6b1b0fc11a28a627897
Play a random embedded youtube video
<!DOCTYPE html>
<html>
<head>
<script>
var videos = ["https://www.youtube.com/embed/9bZkp7q19f0", "https://www.youtube.com/embed/dQw4w9WgXcQ"];
window.onload = function () {
var playerDiv = document.getElementById("random_player");
var player = document.createElement("IFRAME");
var randomVideoUrl = videos[Math.floor(Math.random() * videos.length)];
@arn-ob
arn-ob / auto-move-downloads.py
Created December 4, 2016 15:10 — forked from leninhasda/auto-move-downloads.py
utility script to automatically move the specified files from downloads directory to proper directory
# import
import os
from os import path, listdir as list_dir, rename as move
from os.path import isdir as is_dir, isfile as is_file
from pprint import pprint
import shutil
# global variables
#==================
using System;
using System.Configuration;
using System.Linq;
using System.Reflection;
using System.Threading;
using System.Threading.Tasks;
using log4net;
namespace Watson.Integration
{
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="">
<meta name="author" content="">
<title>app.kodizim.com</title>
<!-- Bootstrap Core CSS -->
@arn-ob
arn-ob / Months.json
Created January 30, 2020 06:09 — forked from enriqueornelasjr/Months.json
Month Names (With Abbreviations) in JSON
[
{
"abbreviation": "Jan",
"name": "January",
"id": "01"
},
{
"abbreviation": "Feb",
"name": "February",
"id": "02"
@arn-ob
arn-ob / node_nginx_ssl.md
Created November 6, 2020 07:47 — forked from bradtraversy/node_nginx_ssl.md
Node app deploy with nginx & SSL

Node.js Deployment

Steps to deploy a Node.js app to DigitalOcean using PM2, NGINX as a reverse proxy and an SSL from LetsEncrypt

1. Sign up for Digital Ocean

If you use the referal link below, you get $10 free (1 or 2 months) https://m.do.co/c/5424d440c63a

2. Create a droplet and log in via ssh

I will be using the root user, but would suggest creating a new user

@arn-ob
arn-ob / docker_wordpress.md
Created April 18, 2021 05:59 — forked from bradtraversy/docker_wordpress.md
Docker Compose FIle For Wordpress, MySQL & phpmyadmin

Wordpress & Docker

This file will setup Wordpress, MySQL & PHPMyAdmin with a single command. Add the code below to a file called "docker-compose.yaml" and run the command

$ docker-compose up -d

# To Tear Down
$ docker-compose down --volumes
@arn-ob
arn-ob / OrdersComponent.tsx
Created September 2, 2021 10:54 — forked from mortezashojaei/OrdersComponent.tsx
Using laravel-echo in reactjs
import React, { FC } from 'react';
import { useSocket } from '@myapp/hooks';
import {Order} from '@myapp/models';
export const OrdersComponent: FC = () => {
const [orders,setOrders] = useState<Order[]>();
function addNewOrder(neworder:Order) {