Skip to content

Commit

Permalink
Search and scraping functionality, “forked” (copied) from WOT-terms
Browse files Browse the repository at this point in the history
  • Loading branch information
kordwarshuis committed Jul 10, 2024
1 parent 8b949bc commit 11bd376
Show file tree
Hide file tree
Showing 63 changed files with 13,820 additions and 0 deletions.
40 changes: 40 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
########################################
### SECRET ENVIRONMENT VARIABLES ###
########################################

# TYPESENSE
TYPESENSE_ADMIN_API_KEY="<your_admin_api_key>"
TYPESENSE_HOST="<your_typesense_host>"
TYPESENSE_COLLECTION_NAME="<your_typesense_collection_name>"

# GITHUB
GITHUB_AUTH_TOKEN="<your_github_auth_token>"
# for creating Github issues:
GITHUB_ISSUE_AUTH_TOKEN="<your_github_issue_auth_token>"


# DOWNLOADS. Add a trailing slash.
# EXAMPLE FOR MACS: KERISSE_BACKUPS_DIR=$HOME/Downloads/
KERISSE_BACKUPS_DIR="<your_kerisse_backups_dir>"


########################################
### NON-SECRET ENVIRONMENT VARIABLES ###
########################################

# SEARCH INDEX DIRECTORY
SEARCH_INDEX_DIR="search-index-typesense"
SEARCH_INDEX_ENTRIES_DIR="search-index-entries"
SEARCH_INDEX_SITEMAPS_DIR="sitemaps"
SEARCH_INDEX_TEMP_DIR="search-index-typesense/temp"

# SITEMAP OF INDEXED WEBSITES VIA FILE SYSTEM
INDEX_OVERVIEW_FILE="docs/02_overview/indexed-in-KERISSE.md"
# SITEMAP OF INDEXED WEBSITES VIA HTTP
INDEX_OVERVIEW_HTTP="/WOT-terms/docs/overview/indexed-in-KERISSE"

# Typesense Restore dir
KERISSE_RESTORE_DIR="search-index-restore"



28 changes: 28 additions & 0 deletions .github/workflows/deploy-to-gh-pages.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Deploy to GitHub Pages

on:
push:
branches:
- main # Set to your default branch

jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- name: Setup Node
uses: actions/setup-node@v2
with:
node-version: '21' # Set to your project's node version

- name: Install and Build
run: |
npm install
npm run build
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./dist
33 changes: 33 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# Dependencies
/node_modules

# Production
/dist

# Generated files
.cache-loader

# Misc
.env
.history
.DS_Store
.ds_store
.idea
.vscode/
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# logs
search-index-typesense/search-index-entries/*
search-index-typesense/logs/*
search-index-typesense/sitemaps/*
search-index-typesense/overrides/overridesID.json
search-index-typesense/singleUrlsFromWotTermsGoogleSheet/*
.history
# media
# *.mp4

copy-to-testsite.sh
docusaurus.paths.*.js
restore.jsonl
22 changes: 22 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<!DOCTYPE html>
<html lang="en">

<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">

<title>Kerisse search</title>

<meta name="description" content="Kerisse search through KERI documentation.">

<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css">
<link rel="stylesheet" href="custom.css">
</head>

<body>
<script src="main.bundle.js"></script>
<script src="additional1.bundle.js"></script>
<script src="additional2.bundle.js"></script>
</body>

</html>
18 changes: 18 additions & 0 deletions indexed-in-KERISSE.html

Large diffs are not rendered by default.

Loading

0 comments on commit 11bd376

Please sign in to comment.