mirror of
https://github.com/pi-hole/pi-hole.git
synced 2024-12-24 13:50:17 +00:00
update
This commit is contained in:
parent
71fd32b1f4
commit
3142992c57
1 changed files with 12 additions and 5 deletions
|
@ -1,17 +1,21 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
# Pi-hole: A black hole for Internet advertisements
|
# Pi-hole: A black hole for Internet advertisements
|
||||||
# by Jacob Salmela
|
|
||||||
# Network-wide ad blocking via your Raspberry Pi
|
|
||||||
#
|
|
||||||
# (c) 2015 by Jacob Salmela
|
# (c) 2015 by Jacob Salmela
|
||||||
# This file is part of Pi-hole.
|
# Network-wide ad blocking via your Raspberry Pi
|
||||||
|
# http://pi-hole.net
|
||||||
|
# Automatically configures the Pi to use the 2.8 LCD screen to display stats on it (also works over ssh)
|
||||||
#
|
#
|
||||||
# Pi-hole is free software: you can redistribute it and/or modify
|
# Pi-hole is free software: you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License as published by
|
# it under the terms of the GNU General Public License as published by
|
||||||
# the Free Software Foundation, either version 2 of the License, or
|
# the Free Software Foundation, either version 2 of the License, or
|
||||||
# (at your option) any later version.
|
# (at your option) any later version.
|
||||||
# pi-hole.net/donate
|
|
||||||
|
|
||||||
|
# Set up the LCD screen based on Adafruits instuctions
|
||||||
|
curl -SLs https://apt.adafruit.com/add-pin | sudo bash
|
||||||
|
sudo apt-get -y install raspberrypi-bootloader
|
||||||
|
sudo apt-get -y install adafruit-pitft-helper
|
||||||
|
|
||||||
|
# Borrowed from somewhere. Will update when I find it.
|
||||||
getInitSys() {
|
getInitSys() {
|
||||||
if command -v systemctl > /dev/null && systemctl | grep -q '\-\.mount'; then
|
if command -v systemctl > /dev/null && systemctl | grep -q '\-\.mount'; then
|
||||||
SYSTEMD=1
|
SYSTEMD=1
|
||||||
|
@ -23,6 +27,7 @@ getInitSys() {
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Borrowed from somewhere. Will update when I find it.
|
||||||
autoLoginPiToConsole() {
|
autoLoginPiToConsole() {
|
||||||
if [ -e /etc/init.d/lightdm ]; then
|
if [ -e /etc/init.d/lightdm ]; then
|
||||||
if [ $SYSTEMD -eq 1 ]; then
|
if [ $SYSTEMD -eq 1 ]; then
|
||||||
|
@ -37,6 +42,7 @@ autoLoginPiToConsole() {
|
||||||
|
|
||||||
|
|
||||||
getInitSys
|
getInitSys
|
||||||
|
|
||||||
# Set pi to log in automatically
|
# Set pi to log in automatically
|
||||||
autoLoginPiToConsole
|
autoLoginPiToConsole
|
||||||
|
|
||||||
|
@ -50,4 +56,5 @@ $SUDO curl -o /etc/default/console-setup https://raw.githubusercontent.com/pi-ho
|
||||||
# Instantly apply the font change to the LCD screen
|
# Instantly apply the font change to the LCD screen
|
||||||
$SUDO setupcon
|
$SUDO setupcon
|
||||||
|
|
||||||
|
# Start chronometer after the settings are applues
|
||||||
$SUDO /usr/local/bin/chronometer.sh
|
$SUDO /usr/local/bin/chronometer.sh
|
||||||
|
|
Loading…
Reference in a new issue