mirror of
https://github.com/kristoferssolo/kristofersxyz.git
synced 2025-10-21 18:30:34 +00:00
Created karbs instruction page
This commit is contained in:
parent
e9ef11bc46
commit
6c00a089fc
0
karbs/__init__.py
Normal file
0
karbs/__init__.py
Normal file
3
karbs/admin.py
Normal file
3
karbs/admin.py
Normal file
@ -0,0 +1,3 @@
|
||||
from django.contrib import admin
|
||||
|
||||
# Register your models here.
|
||||
6
karbs/apps.py
Normal file
6
karbs/apps.py
Normal file
@ -0,0 +1,6 @@
|
||||
from django.apps import AppConfig
|
||||
|
||||
|
||||
class KarbsConfig(AppConfig):
|
||||
default_auto_field = 'django.db.models.BigAutoField'
|
||||
name = 'karbs'
|
||||
0
karbs/migrations/__init__.py
Normal file
0
karbs/migrations/__init__.py
Normal file
3
karbs/models.py
Normal file
3
karbs/models.py
Normal file
@ -0,0 +1,3 @@
|
||||
from django.db import models
|
||||
|
||||
# Create your models here.
|
||||
3
karbs/tests.py
Normal file
3
karbs/tests.py
Normal file
@ -0,0 +1,3 @@
|
||||
from django.test import TestCase
|
||||
|
||||
# Create your tests here.
|
||||
7
karbs/urls.py
Normal file
7
karbs/urls.py
Normal file
@ -0,0 +1,7 @@
|
||||
from django.urls import path
|
||||
from . import views
|
||||
|
||||
urlpatterns = [
|
||||
path('', views.karbs, name='karbs'),
|
||||
path('instructions', views.instructions, name='instructions'),
|
||||
]
|
||||
11
karbs/views.py
Normal file
11
karbs/views.py
Normal file
@ -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'})
|
||||
@ -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)
|
||||
|
||||
@ -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%);
|
||||
}
|
||||
|
||||
61
static/css/karbs.css
Normal file
61
static/css/karbs.css
Normal file
@ -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;
|
||||
}
|
||||
@ -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;
|
||||
}
|
||||
|
||||
51
templates/karbs/instructions.html
Normal file
51
templates/karbs/instructions.html
Normal file
@ -0,0 +1,51 @@
|
||||
{% extends 'layout.html' %}
|
||||
{% load static %}
|
||||
{% block title %} {{ title }} {% endblock %}
|
||||
{% block meta %}
|
||||
<link rel="stylesheet" href="{% static 'css/karbs.css' %}" />
|
||||
{% endblock %}
|
||||
{% block content %}
|
||||
<h1>Kristofers Auto-Rice Bootsrapping Script (KARBS)</h1><hr>
|
||||
|
||||
<p>KARBS is an efficient shell script that will install a fully-featured tiling window manager-based system on any
|
||||
<a href="https://archlinux.org/" target="_blank">Arch</a> or
|
||||
<a href="https://artixlinux.org/" target="_blank">Artix</a>
|
||||
Linux-based system, without any of the routine of manual post-install processes and configuration.</p>
|
||||
<p>By default, KARBS installs and deploys
|
||||
<a href="https://github.com/kristoferssolo/solorice" targer="_blank">my own personal dotfiles</a>.</p>
|
||||
|
||||
<h2>Installation</h2><hr>
|
||||
|
||||
<p>On any (preferrably fresh) install of an
|
||||
<a href="https://archlinux.org/" target="_blank">Arch</a> or
|
||||
<a href="https://artixlinux.org/" target="_blank">Artix</a>
|
||||
Linux, make sure <code>curl</code> is installed and just run the following as the root user:</p>
|
||||
|
||||
<pre><code>curl -LO krisrofers.xyz/karbs.sh
|
||||
sh karbs.sh</code></pre>
|
||||
|
||||
<p>Note that the KARBS scripts will not partition any drives or wipe anything, <strong>but</strong> when it deploys the dotfiles, it will overwrite any preexisting files: e.g. the KARBS .zshrc will replace your old .zshrc, etc.</p>
|
||||
|
||||
<h2>What does KARBS install?</h2><hr>
|
||||
|
||||
<p>You can check out the programs list that KARBS parses for installation <a href="https://github.com/kristoferssolo/karbs/blob/main/pkg-files/minimal-pkgs.txt" target="_blank">right here</a>!</p>
|
||||
|
||||
<p>Here is some idea of the programs installed:</p>
|
||||
|
||||
<aside>If you don't know any of these programs and this is all Greek to you, don't worry because it's all done automatically for you and you will learn as you use the system.</aside>
|
||||
|
||||
<ul class="list">
|
||||
<li><a href="https://awesomewm.org/" target="_blank">awesome</a> - a highly configurable, next generation framework window manager for X</li>
|
||||
<li>Minimalist and keyboard-centric programs for
|
||||
<ul class="list">
|
||||
<li>file management (<a href="https://github.com/gokcehan/lf" target="_blank">lf</a>),</li>
|
||||
<li>video (<a href="https://mpv.io/" target="_blank">mpv</a>),</li>
|
||||
<li>image viewer (<a href="https://github.com/nsxiv/nsxiv" target="_blank">nsxiv</a>),</li>
|
||||
<li>pdf/djvu/epub reader (<a href="https://pwmt.org/projects/zathura/" target="_blank">zathura</a>).</li>
|
||||
</ul>
|
||||
<li>A well featured and configured shell (<a href="https://www.zsh.org/" target="_blank">zsh</a>) and other core programs.</li>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<p>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.</p>
|
||||
{% endblock %}
|
||||
41
templates/karbs/karbs.sh
Executable file
41
templates/karbs/karbs.sh
Executable file
@ -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'
|
||||
@ -19,21 +19,22 @@
|
||||
<div>
|
||||
<ul>
|
||||
<li><a href="{% url 'home' %}">Home</a></li>
|
||||
<li><a href="{% url 'instructions' %}">Karbs</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</header>
|
||||
|
||||
<main>{% block content %}{% endblock %}</main>
|
||||
|
||||
<footer>
|
||||
<p class="footer">
|
||||
Copyright ©
|
||||
<script>
|
||||
document.write(new Date().getFullYear());
|
||||
</script>
|
||||
Kristofers Solo
|
||||
</p>
|
||||
</footer>
|
||||
<!-- <footer> -->
|
||||
<!-- <p class="footer"> -->
|
||||
<!-- Copyright © -->
|
||||
<!-- <script> -->
|
||||
<!-- document.write(new Date().getFullYear()); -->
|
||||
<!-- </script> -->
|
||||
<!-- Kristofers Solo -->
|
||||
<!-- </p> -->
|
||||
<!-- </footer> -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -5,8 +5,8 @@
|
||||
<link rel="stylesheet" href="{% static 'css/index.css' %}" />
|
||||
{% endblock %}
|
||||
{% block content %}
|
||||
<div>
|
||||
<div class="center">
|
||||
<p>At the moment this website is under construction.</p>
|
||||
<p>For now you can check out <a href="">karbs</a>.</p>
|
||||
<p>For now you can check out <a href="{% url 'instructions' %}">KARBS</a>.</p>
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user