Skip to content

Instantly share code, notes, and snippets.


CosmoX hackjutsu

View GitHub Profile

Stevey's Google Platforms Rant

I was at Amazon for about six and a half years, and now I've been at Google for that long. One thing that struck me immediately about the two companies -- an impression that has been reinforced almost daily -- is that Amazon does everything wrong, and Google does everything right. Sure, it's a sweeping generalization, but a surprisingly accurate one. It's pretty crazy. There are probably a hundred or even two hundred different ways you can compare the two companies, and Google is superior in all but three of them, if I recall correctly. I actually did a spreadsheet at one point but Legal wouldn't let me show it to anyone, even though recruiting loved it.

I mean, just to give you a very brief taste: Amazon's recruiting process is fundamentally flawed by having teams hire for themselves, so their hiring bar is incredibly inconsistent across teams, despite various efforts they've made to level it out. And their operations are a mess; they don't real

hackjutsu /
Last active Jan 15, 2022
[Lepton -- 打造GitHub千星项目的经验分享] #tags: lepton
hackjutsu /
Last active Jan 12, 2022
[set upstream] What does '--set-upstream' do? #tags: git
git branch --set-upstream-to <remote-branch>
# example
git branch --set-upstream-to origin feature-branch

# show up which remote branch a local branch is tracking
git branch -vv

sets the default remote branch for the current local branch.

hackjutsu / .leptonrc
Last active Nov 24, 2021
[Template for .leptonrc] This is a template for Lepton's configuration file. Please place it on your home directory. #lepton
View .leptonrc
"theme": "light",
"autoUpdate": false,
"snippet": {
"expanded": true,
"newSnippetPrivate": false,
"sorting": "updated_at",
"sortingReverse": true
"editor" : {
hackjutsu / gai.config
Last active Oct 26, 2021
[IPv4 over IPv6 on Ubuntu] Solved the issue when connecting to takes too long. Edit /etc/gai.conf and uncomment line 4, which lets you keep IPv6 enabled, but sets the order of precedence to prefer IPv4 over IPv6. ( #tags: ubuntu, bittiger
View gai.config
# For sites which prefer IPv4 connections change the last line to
precedence ::ffff:0:0/96 100
hackjutsu / example.js
Last active Jul 1, 2021
[Highlight.js + line number] This snippet adds line number support to Highlight.js. Besides, special css trick is applied to stop the line numbers from being selected and copied. #tags: highlight, lepton
View example.js
import HighlightJS from 'highlight.js'
createHighlightedCodeBlock (content, language) {
let lineNumber = 0
const highlightedContent = HighlightJS.highlightAuto(content, [language]).value
/* Highlight.js wraps comment blocks inside <span class="hljs-comment"></span>.
However, when the multi-line comment block is broken down into diffirent
table rows, only the first row, which is appended by the <span> tag, is
highlighted. The following code fixes it by appending <span> to each line
# installation: pip3 install wordcloud
wordcloud_cli --text mytext.txt --imagefile wordcloud.png
hackjutsu /
Last active Jun 19, 2021
[Lepton V2EX] 记录 #v2ex 上关于 #lepton 的帖子


Lepton 是基于 Gist 的代码片段管理工具( Snippet Manager ),支持 Mac/Windows/Linux。(开源免费)


  • 新增 snippet 雷达图,了解技能增长方向 (如下截图)
  • 新增自动更新功能,无需手动下载
View test.graphql
query {
resolution {
#define section-info
section {
parameters {
hackjutsu /
Last active Nov 20, 2020
[Lepton shortcuts] The shortcut list for #lepton
Function Shortcut Note
New Snippet Cmd/Ctrl + N Create a snippet
Edit Snippet Cmd/Ctrl + E Edit a snippet
Submit Cmd/Ctrl + S Submit the changes from the editor
Cancel Cmd/Ctrl + ESC Exit the editor without saving
Immersive Mode Cmd/Ctrl + I Toggle the Immersive mode
Dashboard Cmd/Ctrl + D Toggle the dashboard
About Page Cmd/Ctrl + , Toggle the About page
Search Shift + Space Toggle the search bar