Skip to content

Instantly share code, notes, and snippets.

@det-peralta
det-peralta / hassio_jetson_nano.sh
Created May 6, 2019 14:22
Install Hassio on Nvidia Jetson Nano
sudo -i
apt-get install software-properties-common
add-apt-repository universe
apt-get update
apt-get install -y apparmor-utils apt-transport-https avahi-daemon ca-certificates curl dbus jq network-manager socat
#The jetson already has docker installed
#curl -fsSL get.docker.com | sh
curl -sL "https://raw.githubusercontent.com/home-assistant/hassio-installer/master/hassio_install.sh" | bash -s -- -m qemuarm-64
@damianpetla
damianpetla / card_background.xml
Last active April 6, 2023 19:05
Android drawable used as background with shadows. Support elevation on API 21+
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:state_pressed="true">
<layer-list>
<!-- Drop Shadow Stack -->
<item>
<shape>
<padding
android:bottom="1dp"
@lopspower
lopspower / README.md
Last active May 11, 2022 02:47
Android Tools Attributes

Android Tools Attributes

Twitter

Android has a dedicated XML namespace intended for tools to be able to record information in XML files, and have that information stripped when the application is packaged such that there is no runtime or download size penalty. The namespace URI is http://schemas.android.com/tools and is usually bound to the tools: prefix:

<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
 android:layout_width="match_parent"
@saxman
saxman / MainActivity.java
Created April 9, 2013 16:31
Plotting markers on a map in Android using data from a JSON web service and the Google Maps Android API v2
/*
* Copyright (c) 2013 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
* in compliance with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software distributed under the License
* is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express