What is Hackers' Pub?

Hackers' Pub is a place for software engineers to share their knowledge and experience with each other. It's also an ActivityPub-enabled social network, so you can follow your favorite hackers in the fediverse and get their latest posts in your feed.

0
2
2
0
1
1

telnet、前から疑問だったんだけど、なんでポートがSSHより大きい23なんだろう? SSHは22なのに(それを言い出したらSMTPの方が25とSSHよりtelnetよりも大きいとかあるが)。気になって夜しか寝られなi……( ˘ω˘)スヤァ

0
0
1
0
0

최근 그냥 코딩 에이전트에게 코딩을 넘어서 삶의 귀찮은 자동화나 일들을 대신 해주는 느낌으로도 쓸 수 있지 않을까 싶어서, 자는 동안 남은 토큰 한도로 epub 파일로 된 소설을 번역시켰더니 꽤 그럴싸한 수준의 번역이 나와서 놀랐다. 그래서 이건 좀 잘 만들어두면 굉장히 편하겠다 싶어서 pdf 파일과 epub 파일을 번역하는걸 Agent Skills로 만들어보았다.

  • PDF or epub 파일 지원
  • 번역 효율과 context window 문제를 피하기 위해 큰 파일은 잘라서 병렬로 하위 Task를 실행하는 형태로 동작
  • PDF의 경우, 텍스트를 추출 과정에서 줄바꿈 등에 대한 후처리
  • epub의 경우, 우종서(중국어나 일본어)나 RTL 방식 언어의 레이아웃에도 대응

Repository

Claude Code에서 pdf translator 스킬을 사용한 화면영어로 된 논문이 잘 번역되어 PDF로도 출력되고 있다.
11
0
0
0
2
0
0
1
2
0
0
0
0
0
1
0
0
0
0
0
1
1

Pillaged from BSky:
Adam Schwarz: "Trump’s Board of Peace logo is basically the UN logo, except dipped in gold and edited so the world only includes America."

Trump already suggested in his Davos speech that his Board of Peace could replace the UN.
But first the Trump/Kushner/Bibi consortium will build a resort on the ruins of .

Adam Schwarz on BSky:
Trump’s Board of Peace logo is basically the UN logo, except dipped in gold and edited so the world only includes America.
Side-by-side photos shows exactly this.
0
0
0
1
0
1

"事務局長の木村壮弁護士は、被告の母による教団への高額な献金被害が量刑に反映されなかったと指摘。「不遇な環境をつくったことには社会全体に責任がある。罪を被告1人に全て背負わせるのが妥当なのか、いま一度考える必要がある」と述べた。"

Well said.

山上被告の成育歴、考慮不十分 全国霊感商法弁連が判決批判 | NEWSjp news.jp/i/1386659082030203062

0
1
1
0
0
0
0
0
0
0
0
1
0

なんらかのスクリプト

'use strict';

const EVIL_DOMAINS = [
    "error-report.com",
    "html-load.com",
    "content-loader.com",
];
const isEvilUrl = (urlString) => {
    if (!urlString) return false;

    const url = (() => {
        try {
            return new URL(urlString);
        } catch {
            return false;
        }
    })();

    return EVIL_DOMAINS.some((evilDomain) => url.hostname.endsWith(evilDomain));
}

const originalRemove = Element.prototype.remove;
Element.prototype.remove = function() {
    if (!["STYLE", "LINK"].includes(this.tagName)) return originalRemove.bind(this);

    // NOP
}

const removeIfEvilIframe = (element) => {
    if (element.src && EVIL_DOMAINS.some((evilDomain) => element.src.includes(evilDomain))) {
        originalRemove.call(element);
    }
};
const observer = new MutationObserver((mutations) => {
    mutations.forEach(({ addedNodes }) => {
        addedNodes.forEach((node) => {
            if (node.nodeType !== Node.ELEMENT_NODE) return;


            if (node.tagName === "IFRAME") {
                removeIfEvilIframe(node);
            }

            if (node.hasChildNodes()) {
                const iframes = node.querySelectorAll("iframe");
                iframes.forEach(removeIfEvilIframe);
            }
        });
    });
});
observer.observe(document, {
    childList: true,
    subtree: true,
});

window.confirm = () => { throw null };
window.navigation.addEventListener("navigate", (event) => {
    if (isEvilUrl(event.destination.url)) {
        event.preventDefault();
    }
});
1
1