This gist contains service descriptors which may be used to automatically start and re-start Minecraft servers using systemd. This allows proper control of your server startup on modern Linux distributions and will automatically manage all required tasks on startup for you.
RewriteEngine On | |
RewriteCond %{REQUEST_FILENAME} !-f | |
RewriteCond %{REQUEST_FILENAME} !-d | |
RewriteRule . index.php [L] |
今天想說重新 review 一次目前所學的 Django 內容 就新開了一個資料夾並且從頭來過 一模一樣的重建一次藉此來複習並熟練
結果在 migrate
的階段噴出錯誤說找不到 zh-TW
OSError: No translation files found for default language zh-TW.
我立刻打開 settings.py
看了看感覺我的設置沒甚麼錯誤阿
First of all, edit your_app_settings/settings.py
and add:
INSTALLED_APPS = [
'django.forms', # to let django discover the built-in widgets
...
]
FORM_RENDERER = 'django.forms.renderers.TemplatesSetting'
#include <stdint.h> | |
#include <stdio.h> | |
#include <stdlib.h> | |
// munged from https://github.com/simontime/Resead | |
namespace sead | |
{ | |
class Random | |
{ |
{{ .Scratch.Set "lastp" (sub (.Params | len) 1) }} | |
<details {{ if .Get 0 | eq "open"}} open {{ end }}> | |
<summary> | |
{{ .Get (.Scratch.Get "lastp") }} | |
</summary> | |
{{ .Inner | markdownify }} | |
</details> |
This is a generic minecraft server setup guide that has been tested on Ubuntu 18.04 and 20.04. By the end of this guide, you will have your very own multiplayer minecraft server that you and your friends (or anyone for that matter) can join and have fun on!
To begin, you will need to provision a VPS from cloud providers such as digitalocean or upcloud. Other popular services like AWS and google cloud would work as well with their EC2 and compute instances but the nature of those services are such that they are slightly more complicated to work with so they will not be included in this guide.
Once you have your VPS provisioned, SSH into your server with the following command (replacing 11.11.11.11 with your server's IP address):
ssh root@11.11.11.11
API_KEY="357A70FF-BFAA-4C6A-8289-9831DDFB2D3D" | |
HOSTNAME="0.0.0.0" | |
PORT="8080" | |
# Optional | |
# DEBUG="True" | |
# ENV="development" |
{{ $htmlTable := .Inner | markdownify }} | |
{{ $old := "<table>" }} | |
{{ $new := "" }} | |
{{ $title := .Get "title" }} | |
{{ $extraClass := .Get "class" }} | |
{{ $id := "" }} | |
{{ with .Get "id" }} | |
{{ $id = . }} | |
{{ else }} | |
{{ $id = delimit (shuffle (seq 1 9)) "" }} |