Skip to content

Instantly share code, notes, and snippets.

View halibegic's full-sized avatar
🎯
Focusing

Hasan Alibegić halibegic

🎯
Focusing
View GitHub Profile
sudo apt-get install lamp-server^
sudo apt-get install phpmyadmin
sudo apt-get install php5-imagick php5-xcache curl php5-curl sqlite php5-sqlite
sudo a2enmod rewrite
sudo a2enmod headers
echo "ServerName localhost" | sudo tee /etc/apache2/conf-available/servername.conf
sudo a2enconf servername
sudo /etc/init.d/apache2 restart
[5] [dash.js 2.2.0] MediaPlayer has been initialized
[8] EME detected on this user agent! (ProtectionModel_3Feb2014)
[10] Playback Initialized
SEC7118: XMLHttpRequest for https://prd-hrt-live.morescreens.com/OIV_HRT1_TV/manifest.mpd?video_id=83&authority_instance_id=spectar-prd-hrt&token=f-iwmd93hfK2fmRC_Jge-g&token_expiration=1476795740&profile_id=4&application_installation_id=5253123&subscriber_id=4&application_id=all_in_one&channel_name=hrt1 required Cross Origin Resource Sharing (CORS).
File: hrti.hrt.hr
[1329] Parsing complete: ( xml2json: 26ms, objectiron: 31ms, total: 0.057s)
[1342] Manifest has been refreshed at Mon Nov 28 2016 08:45:24 GMT+0100 (Central European Standard Time)[1480319124.702]
[1345] SegmentTimeline detected using calculated Live Edge Time
[1350] MediaSource attached to element. Waiting on open...
XML5602: Unexpected end of input.
[3] [dash.js 2.3.0] MediaPlayer has been initialized
[4] EME detected on this user agent! (ProtectionModel_21Jan2015)
[8] Playback Initialized
[151] Parsing complete: ( xml2json: 5.36ms, objectiron: 4.55ms, total: 0.00991s)
[152] Manifest has been refreshed at Fri Dec 02 2016 15:38:09 GMT+0100 (CET)[1480689489.662]
Debug.js:108 [7] EME detected on this user agent! (ProtectionModel_21Jan2015)
Debug.js:108 [10] Playback Initialized
Debug.js:108 [21] [dash.js 2.4.0] MediaPlayer has been initialized
XHRLoader.js:223 XHR finished loading: GET "https://prd-hrt-live.morescreens.com/OIV_HRT1_TV/manifest.mpd?video_id=83&a…ion_id=4852009&subscriber_id=4&application_id=all_in_one&channel_name=hrt1".
c @ XHRLoader.js:223
d @ XHRLoader.js:256
d @ ManifestLoader.js:83
O @ StreamController.js:609
Ub @ MediaPlayer.js:1996
Kb @ MediaPlayer.js:1849
@halibegic
halibegic / Installed packages
Last active April 25, 2017 07:18
List all installed Android packages
pm list packages -f
@import url('https://fonts.googleapis.com/css?family=Ubuntu:400,400i,700,700i&subset=latin-ext');
html * {
font-family: "Ubuntu", sans-serif !important;
}
#overlay {
background: #2e3243;
}
@halibegic
halibegic / changeLanguageSettings.java
Last active July 19, 2017 11:22
Change Android System Language
public void changeLanguageSettings(String language, String country) {
try {
//Set language
Locale locale = new Locale(language, country);
//Getting by reflection the ActivityManagerNative
Class amnClass = Class.forName("android.app.ActivityManagerNative");
Object amn = null;
Configuration config = null;
@halibegic
halibegic / [Android] Enable DEBUG mode in HUAWEI phone
Created November 14, 2017 14:46 — forked from shallowlong/[Android] Enable DEBUG mode in HUAWEI phone
How to enable the "DEBUG" level log in a HUAWEI android phone (not checking the different kinds of HUAWEI phones, but should be okay to use). The problem here is that in the LogCat, the debug level logs cannot be viewed when using a HUAWEI android phone. There are several steps to activate the DEBUG level log inside a HUAWEI phone. This knowledg…
dial *#*#2846579#*#*
select 'ProjectMenu'
select 'Background Setting'
select 'Log Setting'
select 'Log Switch'
enable 'LOG on'
Select 'Log level setting'
enable 'DEBUG'
Press the 'Back' key
select 'Dump and Log'
local hostname="%{$fg_bold[green]%}%m"
local ret_status="%(?:%{$fg_bold[green]%}➜ :%{$fg_bold[red]%}➜ %s)"
PROMPT='${hostname} ${ret_status}%{$fg_bold[green]%}%p %{$fg[cyan]%}%c %{$fg_bold[blue]%}$(git_prompt_info)%{$fg_bold[blue]%}% %{$reset_color%}'
ZSH_THEME_GIT_PROMPT_PREFIX="git:(%{$fg[red]%}"
ZSH_THEME_GIT_PROMPT_SUFFIX="%{$reset_color%}"
ZSH_THEME_GIT_PROMPT_DIRTY="%{$fg[blue]%}) %{$fg[yellow]%}✗%{$reset_color%} "
ZSH_THEME_GIT_PROMPT_CLEAN="%{$fg[blue]%}) "
@halibegic
halibegic / update-namecheap-ddns.sh
Last active October 19, 2018 12:12
Update Namecheap Dynamic DNS
#!/bin/sh
# Config
HOST=@
DOMAIN="your-domain"
PASSWORD="your-password"
# Others
LAST_IP_FILE=/tmp/last-ip.txt
TIME="`date +%Y-%m-%d:%H:%M`"