Skip to content

Instantly share code, notes, and snippets.

View towfiqpiash's full-sized avatar
🌴
On vacation

Towfiqur Rahman towfiqpiash

🌴
On vacation
View GitHub Profile
@towfiqpiash
towfiqpiash / download-from-slideshare.md
Created July 23, 2017 04:58
How to download from slideshare

Right click on the slide image->copy image address, then do curl

curl -O <address>

To downloads all slides, link pattern is important. For example: to download 1–5 pages of the slide:

curl -O https://image.slidesharecdn.com/...[1–5]-638.jpg

Or, visit: http://grub.cballenar.me/

@towfiqpiash
towfiqpiash / html2plainText.js
Last active October 12, 2022 10:54
Javascript function to convert HTML to plain text
// converts HTML to text using Javascript
function html2text(html) {
var tag = document.createElement('div');
tag.innerHTML = html;
return tag.innerText;
}
// Convert Any copied text to plain text in TinyMCE (strip all tags)
paste_preprocess: function(plugin, args) {
@towfiqpiash
towfiqpiash / folder-maker-2d-animation-pipeline.bat
Created June 3, 2022 07:21
This script will create folder structure for 2D animation pipeline
MD "1-Pre Production"\1-Idea "1-Pre Production"\2-Script "1-Pre Production"\3-Concept "1-Pre Production"\4-Audio\1-Dialogue "1-Pre Production"\4-Audio\2-Record "1-Pre Production"\5-Storyboard\1-Board "1-Pre Production"\5-Storyboard\2-Animatic "1-Pre Production"\6-Color "1-Pre Production"\7-Reference
MD 2-Production\1-Assets\1-CH 2-Production\1-Assets\2-BG 2-Production\2-Animation\Scene\Cut
MD "3-Post Production"\"1-Comp asset"\Scene\Cut "3-Post Production"\2-Comp\Scene\Cut "3-Post Production"\3-FX\1-Asset "3-Post Production"\3-FX\2-Comp\Scene\Cut "3-Post Production"\4-Merge\1-Audio\1-Record "3-Post Production"\4-Merge\1-Audio\2-OST "3-Post Production"\4-Merge\"2-M Comp" "3-Post Production"\5-Export\1-Facebook "3-Post Production"\5-Export\2-Instagram "3-Post Production"\5-Export\3-Twitter "3-Post Production"\5-Export\4-Youtube
@towfiqpiash
towfiqpiash / OrganizeFiles.sh
Last active July 4, 2021 20:34
Run this shell script to organize files into separate folders
#!/bin/bash
folders='Compressed Documents Images Music Programs Videos'
ext_comp="*.zip *.tar.gz *.tgz *.rar *.7z"
ext_doc="*.htm* *.php *.txt *.css *.doc* *.pdf *.PDF *.ppt* *.js *.csv"
ext_font="*.ttf"
ext_img="*.jp*g *.JPG *.png *.gif"
ext_music="*.mp3 *.aac *.wma"
ext_progrm="*.deb *.exe *.run *.sh"
ext_vid="*.mp4 *.mkv *.flv *.avi *.webm *.wmv"
@towfiqpiash
towfiqpiash / tricks.md
Last active November 18, 2019 07:01
Handy Tips & Tricks

Tips & Tricks!

Snippets of all helpful commands

Ionic Framework

Run this after clone to restore state

ionic state restore
@towfiqpiash
towfiqpiash / README.md
Created April 24, 2019 09:11 — forked from lopspower/README.md
Hexadecimal color code for transparency

Hexadecimal color code for transparency

Twitter

How to set transparency with hex value ?

For example, you want to set 40% alpha transparence to #000000 (black color), you need to add 66 like this #66000000.

All hex value from 100% to 0% alpha:

@towfiqpiash
towfiqpiash / renamer.py
Last active February 13, 2019 06:28
Bulk file rename using list of file name from a text file
f = open('list.txt', 'r')
mynames = f.readlines()
print(mynames)
f.close()
import os
os.getcwd()
dirname = "/home/piash/Desktop/Test/files/"
for i, filename in enumerate(os.listdir(dirname)):
if 'saved' in filename:
@towfiqpiash
towfiqpiash / empty-value-for-port-specified.md
Created July 23, 2017 05:07
phpmyadmin with Mysql 5.7 - Empty value for 'port' specified

That's because you have the MySQL Password Validation plugin enabled (If you just type 'Y' to the dbconfig-common steps it will be enabled). I find it causes more trouble than good and its requirements (even on low) are superfluous for most. To disable it you'll want to run "UNINSTALL PLUGIN validate_password" once logged into the MySQL server, then try the GRANT again

@towfiqpiash
towfiqpiash / orcale-jdk7-moved-permanently.md
Last active July 26, 2018 07:20
When apt-get installing oracle java 7 stopped working, try this

Or,

Install Oracle JDK 7 We assume that you already downloaded jdk-7u80-linux-x64.tar.gz file from Java archive download page.

Extract the downloaded file.

@towfiqpiash
towfiqpiash / create-wifi-hotspot.md
Last active July 25, 2018 08:47
Create WiFi hotspot on Ubuntu
  1. Disable Wifi (Uncheck Enable Wi-Fi)
  2. Go to network connection (Edit Connections...)
  3. Click "Add"
  4. Choose "Wi-Fi" and click "Create"
  5. Type in Connection name like "wifi-hotspot"
  6. Type in SSID as you wish
  7. Choose Device MAC Address from the dropdown (wlan0)
  8. Wifi Security select "WPA & WPA2 Personal" and set a password.
  9. Go to IPv4 Settings tab, from Method drop-down box select Shared to other computers.
  10. Then save and close.