Skip to content

Instantly share code, notes, and snippets.

View ImaginativeShohag's full-sized avatar
🍟
Already hungry...

Md. Mahmudul Hasan Shohag ImaginativeShohag

🍟
Already hungry...
View GitHub Profile
@ImaginativeShohag
ImaginativeShohag / TabLayout_bottom_line_custom_color.xml
Created March 18, 2020 09:18
Custom color for Android TabLayout bottom line
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
<item
android:left="-10dp"
android:right="-10dp"
android:top="-10dp">
<shape android:shape="rectangle">
<solid android:color="@android:color/transparent" />
<stroke
android:width="2dp"
[Desktop Entry]
Type=Application
Encoding=UTF-8
Name=Shutdown
Comment=Shutdown the System
Icon=system-shutdown
Exec=shutdown -P now
Terminal=false
Categories=Utility
@ImaginativeShohag
ImaginativeShohag / how_to_connect_with_softether_vpn_client_in_linux.md
Last active February 19, 2021 22:05
How to connect with softether vpn client in linux
# ----------------------------------------------------------------
# Start and create vpn connection
# ----------------------------------------------------------------

# Download from https://www.softether-download.com/en.aspx?product=softether
# Select Software: SoftEther VPN (Freeware)
# Select Component: SoftEther VPN Client
# Select Platform: Linux
# Select CPU: Intel x64/AMD64 (64bit)
@ImaginativeShohag
ImaginativeShohag / jetbrains-studio-rc.desktop
Last active March 8, 2021 05:41
Android Studio Release Candidate launch Icon: ~/.local/share/applications/jetbrains-studio-rc.desktop (https://developer.gnome.org/integration-guide/stable/desktop-files.html.en)
[Desktop Entry]
Categories=Development;IDE;
Comment=Everything you need to build on Android
Exec="/mnt/SourceCode/Software/Android/android-studio-rc/bin/studio.sh" %f
Icon=/mnt/SourceCode/Software/Android/android-studio-rc/bin/studio.png
Name=Android Studio RC
StartupWMClass=android-studio-rc
Terminal=false
Type=Application
Version=1.0
@ImaginativeShohag
ImaginativeShohag / whynotimagecarousel-v2-customview.kt
Last active May 22, 2021 06:08
Why Not! Image Carousel! - V2 - Custom View
carousel.carouselListener = object : CarouselListener {
override fun onCreateViewHolder(
layoutInflater: LayoutInflater,
parent: ViewGroup
): ViewBinding? {
// Here, our XML layout file name is custom_item_layout.xml. So our view binding generated class name is CustomItemLayoutBinding.
return CustomItemLayoutBinding.inflate(layoutInflater, parent, false)
}
override fun onBindViewHolder(
@ImaginativeShohag
ImaginativeShohag / generate_android_assets.sh
Last active June 20, 2021 21:03
Generate Android assets for different pixel density
#---------------------------------------------------------------
# Given an xxxhdpi image, this script
# creates different dpis resources and the necessary folders
# if they don't exist
#
# Place this script, as well as the source image, inside res
# folder and execute it passing the image filename as argument
#
# Example:
# ./drawables_dpis_creation.sh my_cool_xxhdpi_image.png