Stephan Wendel f6e2156ab3
Merge develop branch (#163)
* Fix makefile flags on low memory devices (#124)

* Fix `makefile` flags on low memory devices

On devices with less than 512MB existing devices will use `-j2` due to wrong condition.

* docs: Update index with correct heading and link to backends (#131)

This is a follow-up to #108 and fixes heading and hyperlink to the list of backends

* Typo in `core.sh` (#138)

* Fix makefile flags on low memory devices (#124) (#125)

* Fix `makefile` flags on low memory devices

On devices with less than 512MB existing devices will use `-j2` due to wrong condition.

Co-authored-by: Kamil Trzciński <ayufan@ayufan.eu>

* Typo in `core.sh`

'Dependencys' --> dependencies

---------

Co-authored-by: Stephan Wendel <43513802+KwadFan@users.noreply.github.com>
Co-authored-by: Kamil Trzciński <ayufan@ayufan.eu>

* Fix makefile flags on low memory devices (#124) (#125) (#144)

* Fix `makefile` flags on low memory devices

On devices with less than 512MB existing devices will use `-j2` due to wrong condition.

Co-authored-by: Kamil Trzciński <ayufan@ayufan.eu>

* docs(messages.sh): fix typos, improve spelling (#145)

* feat: add legacy cam support (#146)

* feat: add legacy cam support

Signed-off-by: Patrick Gehrsitz <58853838+mryel00@users.noreply.github.com>

* feat: add blockyfix

Signed-off-by: Patrick Gehrsitz <58853838+mryel00@users.noreply.github.com>

* fix: add ustreamer legacy cam workaround

Signed-off-by: Patrick Gehrsitz <58853838+mryel00@users.noreply.github.com>

---------

Signed-off-by: Patrick Gehrsitz <58853838+mryel00@users.noreply.github.com>

* Fix makefile flags on low memory devices (#124) (#125) (#147)

* Fix `makefile` flags on low memory devices

On devices with less than 512MB existing devices will use `-j2` due to wrong condition.

Co-authored-by: Kamil Trzciński <ayufan@ayufan.eu>

* fix: fix make config empty path (#148)

Signed-off-by: Patrick Gehrsitz <58853838+mryel00@users.noreply.github.com>

* fix: fix default_path_msg function name (#149)

* fix: fix default_path_msg function name

Signed-off-by: Patrick Gehrsitz <58853838+mryel00@users.noreply.github.com>

* fix: fix message

Signed-off-by: Patrick Gehrsitz <58853838+mryel00@users.noreply.github.com>

---------

Signed-off-by: Patrick Gehrsitz <58853838+mryel00@users.noreply.github.com>

* fix: fix libcamera-apps-lite not getting updated (#160)

libcamera-apps-lite is needed for libcamera-hello.
Crowsnest uses libcamera-hello to detected raspicams

Signed-off-by: Patrick Gehrsitz <58853838+mryel00@users.noreply.github.com>

* fix: fix Shellcheck test error (#153)

* fix: fix Shellcheck test error

Signed-off-by: Patrick Gehrsitz <58853838+mryel00@users.noreply.github.com>

* style: remove empty condition

Signed-off-by: Patrick Gehrsitz <58853838+mryel00@users.noreply.github.com>

---------

Signed-off-by: Patrick Gehrsitz <58853838+mryel00@users.noreply.github.com>

* fix: fix CustomPiOS docker build error (#158)

This should skip any check of `SUDO_USER`

Tested with Win & Linux host with Docker 

Signed-off-by: Patrick Gehrsitz <58853838+mryel00@users.noreply.github.com>

---------

Signed-off-by: Patrick Gehrsitz <58853838+mryel00@users.noreply.github.com>
Co-authored-by: Kamil Trzciński <ayufan@ayufan.eu>
Co-authored-by: DeviousFusion <dj3tusk@gmail.com>
Co-authored-by: Sergei <67871383+slepiavka@users.noreply.github.com>
Co-authored-by: Patrick Gehrsitz <58853838+mryel00@users.noreply.github.com>
2023-08-11 18:04:33 +02:00

94 lines
2.3 KiB
Bash
Executable File

#!/usr/bin/env bash
#### crowsnest - A webcam Service for multiple Cams and Stream Services.
####
#### Written by Stephan Wendel aka KwadFan <me@stephanwe.de>
#### Copyright 2021 - till today
#### https://github.com/mainsail-crew/crowsnest
####
#### This File is distributed under GPLv3
####
# shellcheck enable=require-variable-braces
### Disable SC2317 due Trap usage
# shellcheck disable=SC2317
# Exit on errors
set -Ee
# Debug
# set -x
TITLE="\e[31mcrowsnest\e[0m - A webcam daemon for multiple cams and stream services."
### Messages
msg() {
echo -e "${1}"
}
status_msg() {
local msg status
msg="${1}"
status="${2}"
echo -en "${msg}\r"
if [[ "${status}" == "0" ]]; then
echo -e "${msg} [\e[32mOK\e[0m]"
fi
if [[ "${status}" == "1" ]]; then
echo -e "${msg} [\e[31mFAILED\e[0m]"
error_msg
exit 1
fi
if [[ "${status}" == "2" ]]; then
echo -e "${msg} [\e[33mSKIPPED\e[0m]"
fi
}
not_as_root_msg() {
msg "\n\tPlease do NOT run this script as root!\n"
msg "\tLogin in as a regular user and run with '\e[32msudo make install\e[0m'\n\n"
}
need_sudo_msg() {
msg "\n\tYou need to run this script with sudo privileges!"
msg "\tPlease try '\e[32msudo make install\e[0m'\n\nExiting..."
}
not_supported_msg() {
msg "\nDebian 10 (buster) has reached end of life.\n"
msg "Therefore, crowsnest has also ended support for it.\n"
msg "Please upgrade to a supported OS release,"
msg "we are sorry for the inconvenience.\n"
}
welcome_msg() {
msg "${TITLE}\n"
msg "\t\e[34mAhoy!\e[0m"
msg "\tThank you for installing crowsnest ;)"
msg "\tThis will take a while ... "
msg "\tPlease reboot after the installation has finished.\n"
sleep 1
}
config_msg() {
msg "\nConfig file not found!\n\tUsing defaults ..."
msg "\tThis uses paths located in 'printer_data' of your home folder."
}
goodbye_msg() {
msg "\nInstallation \e[32msuccessful\e[0m.\n"
msg "\t\e[33mReboot your machine for the changes to take effect!\e[0m\n"
}
unattended_success_msg() {
msg "\nInstallation \e[32msuccessful\e[0m.\n"
}
error_msg() {
msg "Something went wrong!\nPlease copy the latest output, head over to\n"
msg "\thttps://discord.gg/mainsail\n"
msg "and open a ticket in #supportforum..."
}