forked from kofal.net/zmk
Add licenses.
This commit is contained in:
4
docs/static/setup.ps1
vendored
4
docs/static/setup.ps1
vendored
@@ -1,3 +1,7 @@
|
|||||||
|
# Copyright (c) 2020 The ZMK Contributors
|
||||||
|
#
|
||||||
|
# SPDX-License-Identifier: MIT
|
||||||
|
|
||||||
$ErrorActionPreference = "Stop"
|
$ErrorActionPreference = "Stop"
|
||||||
|
|
||||||
function Get-Choice-From-Options {
|
function Get-Choice-From-Options {
|
||||||
|
|||||||
9
docs/static/setup.sh
vendored
9
docs/static/setup.sh
vendored
@@ -1,5 +1,9 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
|
# Copyright (c) 2020 The ZMK Contributors
|
||||||
|
#
|
||||||
|
# SPDX-License-Identifier: MIT
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
check_exists() {
|
check_exists() {
|
||||||
@@ -148,9 +152,10 @@ git commit -m "Initial User Config."
|
|||||||
if [ -n "$github_repo" ]; then
|
if [ -n "$github_repo" ]; then
|
||||||
git remote add origin "$github_repo"
|
git remote add origin "$github_repo"
|
||||||
git push --set-upstream origin "$(git symbolic-ref --short HEAD)"
|
git push --set-upstream origin "$(git symbolic-ref --short HEAD)"
|
||||||
|
push_return_code=$?
|
||||||
|
|
||||||
# If push failed, assume that the origin was incorrect and give instructions on fixing.
|
# If push failed, assume that the origin was incorrect and give instructions on fixing.
|
||||||
if [ $? -ne 0 ] {
|
if [ ${push_return_code} -ne 0 ]; then
|
||||||
echo "Remote repository $github_repo not found..."
|
echo "Remote repository $github_repo not found..."
|
||||||
echo "Check GitHub URL, and try adding again."
|
echo "Check GitHub URL, and try adding again."
|
||||||
echo "Run the following: "
|
echo "Run the following: "
|
||||||
@@ -159,7 +164,7 @@ if [ -n "$github_repo" ]; then
|
|||||||
echo " git push --set-upstream origin $(git symbolic-ref --short HEAD)"
|
echo " git push --set-upstream origin $(git symbolic-ref --short HEAD)"
|
||||||
echo "Once pushed, your firmware should be availalbe from GitHub Actions at: ${github_repo%.git}/actions"
|
echo "Once pushed, your firmware should be availalbe from GitHub Actions at: ${github_repo%.git}/actions"
|
||||||
exit 1
|
exit 1
|
||||||
}
|
fi
|
||||||
|
|
||||||
# TODO: Support determing the actions URL when non-https:// repo URL is used.
|
# TODO: Support determing the actions URL when non-https:// repo URL is used.
|
||||||
if [ "${github_repo}" != "${github_repo#https://}" ]; then
|
if [ "${github_repo}" != "${github_repo#https://}" ]; then
|
||||||
|
|||||||
Reference in New Issue
Block a user