getting closer

This commit is contained in:
Anish Lakhwara 2022-04-03 23:22:35 +10:00
parent 155513a8bd
commit b03568cfcc
15 changed files with 23 additions and 19 deletions

2
.gitignore vendored
View file

@ -5,7 +5,7 @@ __pycache__/*
.tags
.vimwiki_tags
.vim/*
censor.py
.lsp/
.envrc
.direnv/*
./raw/*

View file

@ -1,5 +1,5 @@
from . import mistune
from shared import TagHelper, config
from basant.shared import TagHelper, config
from jinja2 import Environment, FileSystemLoader
import argparse
import glob

View file

@ -6,7 +6,7 @@
# filter - leave names in tact but do not link to relevant documents
# create - list in an index file for website
from basant.shared import TagHelper, config, helpers
from basant.shared.censor import privateList
from basant.shared import censor as c
from os import listdir, mkdir, path, remove
import shutil
from . import convert
@ -14,7 +14,7 @@ import os
# TODO: generalize based on headings(?) in index.wiki
censor = privateList
censor = c.privateList
# TODO put this in config too...
filter = ["dream", "gratitude", "review", "jrnl", "work", "job", "debt",
"people", "priv", "threatdefence", "info"]

View file

@ -1,9 +1,9 @@
import json
import random
from shared import helpers
import shared.censor
from basant.shared import helpers
import basant.shared.censor
censor = shared.censor.privateList
censor = basant.shared.censor.privateList
def loadNetwork(path='network.json'):

View file

@ -1,6 +1,6 @@
import grab.kitaab
from shared import TagHelper
import build.kitaab
import basant.grab.kitaab as grab
from basant.shared import TagHelper
import basant.build.kitaab as build
def get_raw_files():
@ -17,7 +17,7 @@ def build_website():
def main():
get_raw_files()
# get_raw_files()
build_website()

View file

@ -1,8 +1,9 @@
from ctags import CTags, TagEntry
import sys
from os import listdir, path
from . import config
from .censor import privateList
from . import config, censor as c
privateList = c.privateList
def getAllFiles():

2
basant/shared/censor.py Normal file
View file

@ -0,0 +1,2 @@
privateList = ['y0x3y', 'piracy', 'weed', 'drugs', 'gel capsules',
'no weed', 'hackres town', 'hackers.town', 'radicalEd']

View file

@ -8,12 +8,12 @@ build_folder = "output/"
assets_folder = "assets/"
medias_folder = "media/"
raw_folder = "raw/"
template_main = "build/partial/main.html"
template_nav = "build/partial/nav.html"
template_index = "build/partial/index_table.html"
template_list = "build/partial/list.html"
rss_template = "build/partial/rss.xml"
rss_item_template = "build/partial/item.xml"
template_main = "partial/main.html"
template_nav = "partial/nav.html"
template_index = "partial/index_table.html"
template_list = "partial/list.html"
rss_template = "partial/rss.xml"
rss_item_template = "partial/item.xml"
name_of_site = "Kitaab"
site_meta_description = ""
twitter_name = "@aynish@merveilles.town"

View file

@ -39,6 +39,7 @@
src = ./.;
version = "0.1";
propagatedBuildInputs = [ python-with-my-packages ];
doCheck = false;
};
});
}