summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorxengineering <mail2xengineering@protonmail.com>2019-11-12 19:52:27 +0100
committerxengineering <mail2xengineering@protonmail.com>2019-11-12 19:52:27 +0100
commite2fc1f9275e0e8ffe7b8a90ff62723acf1f7d9fe (patch)
tree4264293dca6717a6e25b8da1c0d1a7d7c820086e
parent6eb75bce7f51aa6bf8e5c99f593a37475075554f (diff)
downloadarchinstall-e2fc1f9275e0e8ffe7b8a90ff62723acf1f7d9fe.tar
archinstall-e2fc1f9275e0e8ffe7b8a90ff62723acf1f7d9fe.tar.zst
archinstall-e2fc1f9275e0e8ffe7b8a90ff62723acf1f7d9fe.zip
Moved old attempt for architecture change to archive.
-rw-r--r--bin/config_writer.py51
-rw-r--r--new_archinstall.sh138
2 files changed, 0 insertions, 189 deletions
diff --git a/bin/config_writer.py b/bin/config_writer.py
deleted file mode 100644
index 529ec7e..0000000
--- a/bin/config_writer.py
+++ /dev/null
@@ -1,51 +0,0 @@
-#!/usr/bin/env python
-
-
-# archinstall - A minimal Installation Script for Arch Linux
-# Copyright (C) 2019 xengineering
-
-# This program is free software: you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
-
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see <https://www.gnu.org/licenses/>.
-
-
-######################
-# config_writer.py #
-######################
-
-
-import sys
-import json
-
-
-log_file_path = sys.argv[1]
-config_file_path = sys.argv[2]
-
-
-def output(text):
- print(text)
- print("")
- with open(log_file_path, 'a') as f:
- f.write(text)
- f.write("")
-
-
-config = {}
-
-
-config["test"] = "testing"
-config["test2"] = 2
-
-config_json = json.dumps(config, indent=4)
-
-with open(config_file_path, 'w') as f:
- f.write(config_json)
diff --git a/new_archinstall.sh b/new_archinstall.sh
deleted file mode 100644
index 414dc68..0000000
--- a/new_archinstall.sh
+++ /dev/null
@@ -1,138 +0,0 @@
-#!/bin/bash
-
-
-# archinstall - A minimal Installation Script for Arch Linux
-# Copyright (C) 2019 xengineering
-
-# This program is free software: you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
-
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see <https://www.gnu.org/licenses/>.
-
-
-#################################################################
-# _ _ _ _ _ #
-# __ _ _ __ ___| |__ (_)_ __ ___| |_ __ _| | | ___| |__ #
-# / _` | '__/ __| '_ \| | '_ \/ __| __/ _` | | | / __| '_ \ #
-# | (_| | | | (__| | | | | | | \__ \ || (_| | | |_\__ \ | | | #
-# \__,_|_| \___|_| |_|_|_| |_|___/\__\__,_|_|_(_)___/_| |_| #
-# #
-#################################################################
-
-
-# Static config
-
-TESTSERVER="8.8.8.8" # hostnames will not work properly
-LOG_FILE_PATH="/var/log/archinstall.log"
-REPOSITORY_URL="https://github.com/xengineering/archinstall/"
-REPOSITORY_PATH="/opt/archinstall.git"
-BRANCH_OR_COMMIT="master"
-SCRIPT_BASE_PATH=$REPOSITORY_PATH
-SCRIPT_BASE_PATH+="/bin/"
-CONFIG_FILE_FOLDER_PATH="/etc/archinstall/"
-CONFIG_FILE_PATH=$CONFIG_FILE_FOLDER_PATH
-CONFIG_FILE_PATH+="config.json"
-DELAY=0.5
-
-
-# Initial message
-
-cat << EOF
-
-#################################################################
-# #
-# Arch Linux Installation Script #
-# #
-# archinstall Copyright (C) 2019 xengineering #
-# This program comes with ABSOLUTELY NO WARRANTY. #
-# This is free software, and you are welcome to redistribute it #
-# under certain conditions. See #
-# <https://www.gnu.org/licenses/gpl-3.0.en.html> for details. #
-# #
-#################################################################
-
-EOF
-
-
-# Create log and provide output function ...
-
-touch $LOG_FILE_PATH
-echo "" > $LOG_FILE_PATH
-output () {
- echo $1 | tee -a $LOG_FILE_PATH
- echo "" | tee -a $LOG_FILE_PATH
- sleep $DELAY
-}
-output "Log created - OK"
-
-
-output "Checking if booted with UEFI ..."
-
-if [ -d "/sys/firmware/efi/efivars" ]; then
- output "Booted with UEFI - OK"
-else
- output "Not booted with UEFI. Please enable it in your mainboard settings. - FAILED"
- exit
-fi
-
-
-output "Check internet connection ..."
-
-if ping -w 3 -c 1 $TESTSERVER > /dev/null; then
- output "Internet connection is ready - OK"
-else
- output "Could not reach testserver '$TESTSERVER' - FAILED"
- exit
-fi
-
-
-output "Update system clock ..."
-
-timedatectl set-ntp true
-if [ $? -eq 0 ]; then
- output "Updated system clock - OK"
-else
- output "Could not update system clock - FAILED"
- exit
-fi
-
-
-output "Cloning git repository ..."
-
-pacman --noconfirm -Sy git | tee -a $LOG_FILE_PATH
-mkdir $REPOSITORY_PATH
-git clone $REPOSITORY_URL $REPOSITORY_PATH | tee -a $LOG_FILE_PATH
-cd $REPOSITORY_PATH && git checkout $BRANCH_OR_COMMIT | tee -a $LOG_FILE_PATH
-cd
-output "Git repository cloned - OK"
-
-
-output "Generating config ..."
-
-script_path=$SCRIPT_BASE_PATH
-script_path+="config_writer.py"
-mkdir $CONFIG_FILE_FOLDER_PATH
-touch $CONFIG_FILE_PATH
-python $script_path $LOG_FILE_PATH $CONFIG_FILE_PATH
-output "Generated config - OK"
-
-
-# Generate new system ...
-
-
-# Copy everything to new system
-
-# log
-# repo
-# config
-
-
-# Unmount new system