Skip to content

Instantly share code, notes, and snippets.

View lookoutking's full-sized avatar

lookoutking

  • Taiwan
  • 22:42 (UTC +08:00)
View GitHub Profile
/specify Build a Telegram bot that allows me to save bookmarks into a self-hosted Linkding instance.
When I send the /bookmark command in Telegram with a URL and tags, the bot should store the URL into Linkding including the specified tags.
The bot must validate tags against a predefined tagging system to avoid uncontrolled tag growth.
This tagging system is maintained in the codebase, and any updates require redeployment.
The purpose of this tool is to unify my saved web content from sources like Twitter bookmarks and Safari into Linkding with consistent tagging.
@lookoutking
lookoutking / ruby.html
Created October 2, 2024 13:48
Hugo markdown furigana/ruby shortcode
<!--{{< ruby "振り仮名" "ふりがな" >}}-->
<ruby>
{{ .Get 0 }}<rp>(</rp><rt>{{ .Get 1 }}</rt><rp>)</rp>
</ruby>
@lookoutking
lookoutking / PlainSRTLoader.py
Created November 12, 2023 07:51
langflow custom SRT loader with CustomComponent
from langflow import CustomComponent
from langchain.schema import Document
class PlainSRTLoader(CustomComponent):
display_name: str = "Plain SRT Loader"
description: str = "Read .srt file as plain text"
def build_config(self):
return {
'uploaded_file': {
@lookoutking
lookoutking / Builder.cs
Created November 3, 2022 09:28
Unity build script with AR Platform (iOS/Android) Settings
using UnityEditor;
using System.Linq;
using System;
using System.IO;
using UnityEditor.XR.Management;
using UnityEngine.XR.Management;
using UnityEditor.XR.Management.Metadata;
static class Builder
{
@lookoutking
lookoutking / ARCameraStreamSender.cs
Created July 6, 2022 07:38
ARFoundation Camera Frame Sender for Unity Render Streaming package
using System.Collections.Generic;
using Unity.WebRTC;
using UnityEngine;
using UnityEngine.Experimental.Rendering;
using UnityEngine.Rendering;
using Unity.RenderStreaming;
using UnityEngine.XR.ARFoundation;
using UnityEngine.XR.ARSubsystems;
using Unity.Collections;
using System;