Skip to content

Instantly share code, notes, and snippets.

View mkheck's full-sized avatar
💭
Coding, of course!

Mark Heckler mkheck

💭
Coding, of course!
View GitHub Profile
@mkheck
mkheck / gist:5066119
Created March 1, 2013 17:04
Using an anonymous inner class for User Info column's cell factory. Associated blog post: https://blogs.oracle.com/javajungle/entry/how_to_pretty_up_your
userInfoCol.setCellFactory(new Callback<TableColumn<MTweet, MUser>,
TableCell<MTweet, MUser>>() {
@Override
public TableCell<MTweet, MUser> call(TableColumn<MTweet, MUser> param) {
return new TableCell<MTweet, MUser>() {
VBox vb;
Label userName;
Label screenName;
ImageView imgVw;
@mkheck
mkheck / interfaces
Created February 28, 2015 15:08
Content of Raspberry Pi (Raspbian) /etc/network/interfaces file for connection to hidden SSIDs
auto lo
iface lo inet loopback
iface eth0 inet dhcp
allow-hotplug wlan0
iface wlan0 inet manual
wpa-roam /etc/wpa_supplicant/wpa_supplicant.conf
iface default inet dhcp
@mkheck
mkheck / wpa_supplicant-HIDDEN
Last active March 19, 2023 19:01
Content of Raspberry Pi (Raspbian) /etc/wpa_supplicant/wpa_supplicant.conf file for connection to hidden SSIDs
network={
ssid="put_your_hidden_ssid_here"
scan_ssid=1
psk="put_your_password_for_network_here"
mode=0
proto=WPA2
key_mgmt=WPA-PSK
pairwise=CCMP
group=CCMP
auth_alg=OPEN
@mkheck
mkheck / wpa_supplicant.conf-UNHIDDEN
Last active August 29, 2015 14:16
Entry in Raspberry Pi (Raspbian) /etc/wpa_supplicant/wpa_supplicant.conf file network section for UNhidden SSID
disabled=1
package org.thehecklers;
import org.springframework.stereotype.Component;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
@Entity
package org.thehecklers;
import org.springframework.data.repository.CrudRepository;
import org.springframework.data.rest.core.annotation.RepositoryRestResource;
@RepositoryRestResource
public interface ReadingRepository extends CrudRepository<Reading, Long> {
}
curl -X POST -H "Content-Type: application/json" -d "{\"temperature\": 26.0, \"humidity\": 35.0}" localhost:8080/readings
curl localhost:8080/readings
{
"_embedded" : {
"readings" : [ {
"temperature" : 25.0,
"humidity" : 34.0,
"_links" : {
"self" : {
"href" : "http://localhost:8080/readings/1"
},
"reading" : {
---
applications:
- name: example-app
path: target/example-app-0.0.1-SNAPSHOT.jar
memory: 512M
random-route: true