diff --git a/karbs/__init__.py b/karbs/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/karbs/admin.py b/karbs/admin.py new file mode 100644 index 0000000..8c38f3f --- /dev/null +++ b/karbs/admin.py @@ -0,0 +1,3 @@ +from django.contrib import admin + +# Register your models here. diff --git a/karbs/apps.py b/karbs/apps.py new file mode 100644 index 0000000..af72bd2 --- /dev/null +++ b/karbs/apps.py @@ -0,0 +1,6 @@ +from django.apps import AppConfig + + +class KarbsConfig(AppConfig): + default_auto_field = 'django.db.models.BigAutoField' + name = 'karbs' diff --git a/karbs/migrations/__init__.py b/karbs/migrations/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/karbs/models.py b/karbs/models.py new file mode 100644 index 0000000..71a8362 --- /dev/null +++ b/karbs/models.py @@ -0,0 +1,3 @@ +from django.db import models + +# Create your models here. diff --git a/karbs/tests.py b/karbs/tests.py new file mode 100644 index 0000000..7ce503c --- /dev/null +++ b/karbs/tests.py @@ -0,0 +1,3 @@ +from django.test import TestCase + +# Create your tests here. diff --git a/karbs/urls.py b/karbs/urls.py new file mode 100644 index 0000000..2fa0da0 --- /dev/null +++ b/karbs/urls.py @@ -0,0 +1,7 @@ +from django.urls import path +from . import views + +urlpatterns = [ + path('', views.karbs, name='karbs'), + path('instructions', views.instructions, name='instructions'), +] diff --git a/karbs/views.py b/karbs/views.py new file mode 100644 index 0000000..d0778dd --- /dev/null +++ b/karbs/views.py @@ -0,0 +1,11 @@ +from django.shortcuts import render, redirect + + +def instructions(request): + """Karbs Instruction""" + return render(request, 'karbs/instructions.html', {'title': 'Karbs Instructions'}) + + +def karbs(request): + """Karbs install script""" + return render(request, 'karbs/karbs.sh', {'title': 'KARBS'}) diff --git a/kristofersxyz/urls.py b/kristofersxyz/urls.py index d5c56f0..7e36e69 100644 --- a/kristofersxyz/urls.py +++ b/kristofersxyz/urls.py @@ -21,4 +21,5 @@ from django.conf.urls.static import static urlpatterns = [ path('admin/', admin.site.urls), path('', include('main.urls')), + path('karbs.sh/', include('karbs.urls')), ] + static(settings.STATIC_URL, document_root=settings.STATIC_ROOT) diff --git a/static/css/index.css b/static/css/index.css index ec8716e..2d778cf 100644 --- a/static/css/index.css +++ b/static/css/index.css @@ -1,5 +1,25 @@ p { + color: #f0f6fc; font-size: 20px; text-align: center; margin-top: 10px; } + +a { + text-decoration: none; + font-weight: bold; + color: #58a6ff; +} + +a:hover { + text-decoration: underline; +} + +.center { + margin: 0; + position: absolute; + top: 50%; + left: 50%; + -ms-transform: translate(-50%, -50%); + transform: translate(-50%, -50%); +} diff --git a/static/css/karbs.css b/static/css/karbs.css new file mode 100644 index 0000000..5e9f694 --- /dev/null +++ b/static/css/karbs.css @@ -0,0 +1,61 @@ +main { + border-color: #30363d; + border-style: solid; + border-width: 1px; + max-width: 700px; + color: #f0f6fc; + padding: 50px; + margin: 100px auto 100px auto; +} + +hr { + color: #30363d; +} + +h1 { + text-align: center; +} + +h2 { + margin: 40px 0 0 0; +} + +p { + font-size: 18px; + margin: 10px 0; +} + +a { + text-decoration: none; + font-weight: bold; + color: #58a6ff; +} + +a:hover { + text-decoration: underline; +} + +code { + font-family: Consolas, 'courier new'; + color: #f0f6fc; + background-color: #393f48; + border-radius: 8px; + padding: 3px; +} + +pre code { + background-color: #161b22; + display: block; + padding: 20px; +} + +aside { + color: #8b949e; + font-size: 12px; + margin: 10px 0; + font-style: italic; +} + +.list { + margin: 10px 40px; +} diff --git a/static/css/layout.css b/static/css/layout.css index d597868..0762c80 100644 --- a/static/css/layout.css +++ b/static/css/layout.css @@ -88,7 +88,7 @@ video { html, body { font-family: 'Roboto', sans-serif; - background: #f2f2f2; + background: #0d1117; } main { @@ -98,43 +98,32 @@ main { /* HEADER */ header ul { + width: 100%; list-style-type: none; overflow: hidden; - background-color: #333333; + background-color: #161b22; position: sticky; - position: -webkit-sticky; top: 0; +} + +header li { text-align: center; - z-index: 100; font-weight: bold; - width: 100%; -} - -.material-icons { - position: relative; - top: 4px; - font-size: 25px; -} - -li { - font-size: 18px; + font-size: 24px; float: left; - display: inline-block; width: calc(100% / 2); } -li a { +header li a { display: inline-block; - color: #cccccc; + color: #f0f6fc; padding: 14px 16px; text-decoration: none; - transition: transform 0.7s ease; } -li a:hover { +header li a:hover { text-decoration: none; - color: #fff; - transform: scale(1.05); + color: #b9bbbd; } /* FOOTER */ @@ -153,14 +142,14 @@ footer { bottom: 0; width: 100%; height: auto; - background-color: #333333; - color: #666666; + background-color: #161b22; + color: #f0f6fc; flex-wrap: wrap; display: flex; justify-content: space-around; - padding: 8px 0; } footer p { font-size: 16px; + margin: 10px 0; } diff --git a/templates/karbs/instructions.html b/templates/karbs/instructions.html new file mode 100644 index 0000000..b31fefb --- /dev/null +++ b/templates/karbs/instructions.html @@ -0,0 +1,51 @@ +{% extends 'layout.html' %} +{% load static %} +{% block title %} {{ title }} {% endblock %} +{% block meta %} + +{% endblock %} +{% block content %} +

Kristofers Auto-Rice Bootsrapping Script (KARBS)


+ +

KARBS is an efficient shell script that will install a fully-featured tiling window manager-based system on any + Arch or + Artix + Linux-based system, without any of the routine of manual post-install processes and configuration.

+

By default, KARBS installs and deploys + my own personal dotfiles.

+ +

Installation


+ +

On any (preferrably fresh) install of an + Arch or + Artix + Linux, make sure curl is installed and just run the following as the root user:

+ +
curl -LO krisrofers.xyz/karbs.sh
+sh karbs.sh
+ +

Note that the KARBS scripts will not partition any drives or wipe anything, but when it deploys the dotfiles, it will overwrite any preexisting files: e.g. the KARBS .zshrc will replace your old .zshrc, etc.

+ +

What does KARBS install?


+ +

You can check out the programs list that KARBS parses for installation right here!

+ +

Here is some idea of the programs installed:

+ + + + + +

Note that making your own fork of KARBS is as easy as using your own dotfiles, making a programs file like the one above, and making any other direct changes to the script you want.

+{% endblock %} diff --git a/templates/karbs/karbs.sh b/templates/karbs/karbs.sh new file mode 100755 index 0000000..7fb52bf --- /dev/null +++ b/templates/karbs/karbs.sh @@ -0,0 +1,41 @@ +#!/bin/sh +echo 'Choose installation size: minimal or full' +read size + +if pacman -Q paru; then + echo +else + sudo pacman -S --noconfirm rust + git clone 'https://aur.archlinux.org/paru-bin' + cd paru-bin + makepkg -si + cd .. + rm -rf paru-bin +fi + +FILE = "pkg-files/$size-pkgs.txt" + +if [[ -f "$FILE" ]]; then + paru -Syu --noconfirm --needed - <"pkg-files/$size-pkgs.txt" +else + curl -LO "https://raw.githubusercontent.com/kristoferssolo/karbs/main/pkg-files/$size-pkgs.txt" + paru -Syu --noconfirm --needed - <"$size-pkgs.txt" + rm "$size"-pkgs.txt +fi + +mkdir -p "$HOME"/{repos,Downloads,Documents,Videos,Music,Pictures/screenshots} +git clone 'https://github.com/kristoferssolo/solorice' "$HOME/repos/solorice" + +cp -rf "$HOME/repos/solorice/.config" "$HOME" +rm -rf "$HOME/.config/awesome/desktop" +touch "$HOME/.config/awesome/weather" +cp -rf "$HOME/repos/solorice/.local" "$HOME" +ln -rfs "$HOME/.config/zsh/.zshenv" "$HOME" +git clone 'https://github.com/streetturtle/awesome-wm-widgets' "$HOME/.config/awesome/awesome-wm-widgets" + +chsh -s /bin/zsh +sudo chmod +s /usr/bin/reboot + +echo +echo +echo -e '\033[1;31m For weather widget to work, enter API-key from https://openweathermap.org, latitude and logitude in `~/.config/awesome/weather` file, each on seperate line. \033[0m' diff --git a/templates/layout.html b/templates/layout.html index a7cbfd6..55fb623 100644 --- a/templates/layout.html +++ b/templates/layout.html @@ -19,21 +19,22 @@
{% block content %}{% endblock %}
- + + + + + + + + + diff --git a/templates/main/index.html b/templates/main/index.html index 3107463..ae26875 100644 --- a/templates/main/index.html +++ b/templates/main/index.html @@ -5,8 +5,8 @@ {% endblock %} {% block content %} -
+

At the moment this website is under construction.

-

For now you can check out karbs.

+

For now you can check out KARBS.

{% endblock %}