Skip to content

Instantly share code, notes, and snippets.

View skinzor's full-sized avatar
🎯
Focusing

skinzor

🎯
Focusing
  • Bucharest, Romania
View GitHub Profile
@skinzor
skinzor / install-discord.bash
Created November 21, 2017 18:32
Install discord (for the .tar.gz)
#!/usr/bin/env bash
cd ~/
mkdir -p ~/.local/bin
wget "https://discordapp.com/api/download/canary?platform=linux&format=tar.gz" -O discord.tar.gz
tar -xvf discord.tar.gz -C ~/.local/bin
sudo ln -s ~/.local/bin/DiscordCanary/discord.png /usr/share/icons/discord.png
sudo ln -s ~/.local/bin/DiscordCanary/DiscordCanary /usr/bin
wget https://gist.githubusercontent.com/AdrianKoshka/a12ca0bfe2f334a9f208aff72f8738c3/raw/9d606ad7ce7cc1dd23f6a99993e2396540538a02/discord.desktop -O discord.desktop
mkdir -p ~/.local/share/applications/
mv ~/discord.desktop ~/.local/share/applications/
@skinzor
skinzor / gist:c93de87fd0c8c06b6025450e591d16a3
Created December 28, 2017 21:23 — forked from DD3Boh/gist:6c51fd3c5f91b1042e956771483714de
How to merge a newer CAF tag in an android kernel
First go here:
https://wiki.codeaurora.org/xwiki/bin/QAEP/release
This site gives information about all msm soc release details with tag + android version
Search your msm here.. Check the latest one and look for correct android version and mark that tag.
Now open one of the following links (dependent on your linux kernel version)
@skinzor
skinzor / gist:c9c706df6d98ee5c01687f2f147a4fd3
Created December 28, 2017 21:30
Keeping a fork up to date

1. Clone your fork:

git clone git@github.com:YOUR-USERNAME/YOUR-FORKED-REPO.git

2. Add remote from original repository in your forked repository:

cd into/cloned/fork-repo
git remote add upstream git://github.com/ORIGINAL-DEV-USERNAME/REPO-YOU-FORKED-FROM.git
git fetch upstream
@skinzor
skinzor / h264-fedora-25.markdown
Created January 4, 2018 12:26
Enable H.264 in Firefox on Fedora 25

Enable H.264 in Firefox on Fedora 25

sudo dnf install gstreamer1-libav gstreamer1-vaapi gstreamer1-plugins-{good,good-extras,ugly} -y
sudo dnf config-manager --set-enabled fedora-cisco-openh264
sudo dnf install gstreamer1-plugin-openh264 mozilla-openh264
  • Enable Firefox plugin.
@skinzor
skinzor / audit2allow-sepolicy-android
Created January 12, 2018 11:23 — forked from Nihhaar/audit2allow-sepolicy-android
Addressing selinux denials using audit2allow for android using logcat
# Goto android source code root and then execute following commands
# Keep the logcat.log in the root
export ANDROID_BUILD_TOP=$(pwd)
./external/selinux/prebuilts/bin/audit2allow -p out/target/product/{devicename}/root/sepolicy < logcat.log
# Copy the generated rules in respective files in the device tree
@skinzor
skinzor / gist:8e4642bf8eba2fe480636183e99ad4f2
Created January 25, 2018 09:27 — forked from msfjarvis/sepolicy.md
How to write sepolicy to fix a denial

Denial in question

avc: denied { read write } for pid=29059 comm="i.tetherservice" name="ipa" dev="tmpfs" ino=11991 scontext=u:r:system_app:s0 tcontext=u:object_r:ipa_dev:s0 tclass=chr_file permissive=0

sepolicy fix

allow system_app ipa_dev:chr_file {read write};
TW_OEM_BUILD --
TARGET_USERIMAGES_USE_EXT4 -- Adds EXT4 formatting binaries
TWHAVE_SELINUX -- Sets SELinux inclusion status
TW_INCLUDE_MTP
TW_NO_SCREEN_TIMEOUT
BOARD_HAS_NO_REAL_SDCARD
SP1_NAME
SP1_DISPLAY_NAME
RECOVERY_SDCARD_ON_DATA
TW_INCLUDE_DUMLOCK
#!/bin/bash
if [ $UID != "0" ]; then
echo "ERROR: You must run this script as root!"
exit 1
fi
dnf install \
@development-tools \
android-tools \
automake \
package com.demotxt.myapp.myapplication.model;
/**
* Created by Aws on 22/02/2018.
*/
public class Anime {
private String name ;
private String description;
[
{
"name": "Naruto: Shippuuden",
"description": "It has been two and a half years since Naruto Uzumaki left Konohagakure, the Hidden Leaf Village, for intense training following events which fueled his desire to be stronger. Now Akatsuki, the mysterious organization of elite rogue ninja, is closing in on their grand plan which may threaten the safety of the entire shinobi world.",
"Rating": "8.16",
"episode": 500,
"categorie":"Animation | Drama | Adventure",
"studio":"Studio Pierrot",
"img": "https://myanimelist.cdn-dena.com/images/anime/5/17407.jpg"
},