Upgrade to Pro — share decks privately, control downloads, hide ads and more …

開発環境へのこだわり

 開発環境へのこだわり

Eabad423977cfc6873b8f5df62b848a6?s=128

SHIBATA Hiroshi

June 10, 2022
Tweet

More Decks by SHIBATA Hiroshi

Other Decks in Technology

Transcript

  1. ։ൃ؀ڥ΁ͷͩ͜ΘΓ @hsbt

  2. ࡉ͔͗ͯ͢఻ΘΒͳ͍ @hsbt ͷ։ൃ؀ڥ(खݩͷϚγϯ)ͷ࿩Λ͠·͢ɻ @hsbt ͸͜ΕͰੜ࢈ੑ͋͛ͯΔͱ͍͏͚ͩͷ࿩ͳͷͰɺͦΕͧΕʹ͋ͬͨ࠷ߴ ͷ΍Γํ͸޻෉͍ͯͩ͘͠͞ɻ ࠓ೔࿩͢͜ͱ

  3. • macOS, Windows, Linux ΋શ෦࢖͏ͷͰ platform ʹϩοΫ͞ΕΔ΋ͷ͸࢖ Θͳ͍ ◦ macOS

    (Windows) Ͱ͚ͩಈ͘ GUI ΞϓϦ ◦ homebrew, scoop, apt(dnf) ͰखʹೖΒͳ͍ίϚϯυ ◦ Go, Rust ͰγϡοͱϏϧυͰ͖ͳ͍ίϚϯυ جຊతͳߟ͑ํ
  4. • هԱ(҉ه)͠ͳ͍ ◦ ਓؒͷهԱྗʹ͸ݶք͕͋ΔͷͰͦΕʹཔΒͳ͍ ◦ ಛ௃తͳϫʔυ͚ͩͰಛఆͰ͖Δ࢓૊ΈΛ࢖͏ • ੵۃతʹΞϯϥʔχϯά͢Δ ◦ https://rebuild.fm/169/

    Λฉ͍ͯ΄͍͠ ◦ ίϯϐϡʔςΟϯά؀ڥ͕໨·͙Δ͘͠มΘΔੈͷதͰݹ͍΍Γํ͕ ͍ͭ·Ͱ΋͍͍ͱ͸ࢥΘͳ͍ɻֵ৽೿ɻ جຊతͳߟ͑ํ
  5. • ΧελϚΠζ͸͋·Γ͠ͳ͍ɺϓϥάΠϯ΋͋·Γ࢖Θͳ͍ ◦ όουϊ΢ϋ΢ͱʮԞ͕ਂ͍঱ީ܈ʯ ΛಡΜͰ͍ͩ͘͞ ◦ ͦ΋ͦ΋ಓ۩͸ͦͷ··Ͱ࢖͍΍͍͢΋ͷͰ͋Δ΂͖ ▪ Git ͸࠷ѱ!(͚ͩͲ͠ΐ͏͕ͳ͍ͷͰ࢖͏)

    • https://github.com/hsbt/hsbt/tree/master/toolbox/xdg/config/fish ͕શ෦ ◦ xdg ʹͱʹ͔͘دͤΔͨΊʹ؀ڥม਺͚ͩ͠ΐ͏͕ͳ͘ઃఆ͍ͯ͠Δ ◦ alias ͱ͔ઃఆͯ͠΋ fuzzy finder ͕༏लͳΒ࢖Θͳ͍... γΣϧ͸ fish
  6. • fzf, peco • zoxide, autojump, z ਓ͕ؒҰੜʹλΠϓͰ͖ΔΩʔͷ਺ʹ͸ݶք͕͋ΔͷͰগͳ͍਺Ͱ͍͍ײ͡ʹ ͢Δ fuzzy

    finder Λ࢖͍·͘Δ
  7. • ϖύϘʹೖࣾͯ͠10೥ԹΊͨൿ఻ͷλϨ ◦ ೖࣾͨ͠͹͔Γͩͱཤྺ͕ͳ͍ͷ͸ͦΕ͸ͦ͏... • fish ͷཤྺ΋ fuzzy find Ͱ࢖͏

    (fzf ֦ுͳͷ͔ built-in ͳͷ͔ௐ΂͍ͯͳ͍) • ϓϥοτϑΥʔϜΛލ͍Ͱ͍͍ײ͡ʹͰ͖ͳ͍ͷ͕ͩΔ͍ ◦ ಛʹ fish ͸ಠࣗܗࣜͳͷ͕ͪΐͬͱ... ཤྺΛ࢖͏
  8. • find ΑΓ fd • grep ΑΓ ripgrep • sed

    ΑΓ sd • cat ΑΓ bat • dig ΑΓ dog • man ΑΓ tealdeer(tldr ͷ࣮૷͸৭ʑ͋ΔͷͰ޷͖ͳ΍ͭ࢖͏) ෳࡶͳΦϓγϣϯΛ֮͑Δͷ͸࣌ؒͷແବɺඞཁͳ࣌ʹௐ΂Ε͹ྑ͍ Rust Ͱॻ͔Εͨ࣍ੈ୅πʔϧ͸଎͍ɺ࢖͍΍͍͢
  9. Q. “Rust ͷπʔϧ͕αʔόʔʹΠϯετʔϧ͞Εͯͳ͍͜ͱ΋͋ΔΜͰ͸?” A. “ผʹ GNU πʔϧ΋࠷௿ϨϕϧͰ͸࢖͑ΔΜͰ໰୊ͳ͍Ͱ͢” ͱݴ͍੾ΕΔ͘Β͍ʹ͸྆ํ࢖͑ΔΑ͏ʹ͓ͯ͘͠ɻ Α͋͘Δ൓࿦

  10. • workspace Λ׆༻ ◦ “code -a .” Λ e ʹ

    alias ◦ ؔ܎͋ΔϦϙδτϦ͸શ෦ vscode ʹಥͬࠐΉ(-a Φϓγϣϯ) • vscode ͷىಈ͸ “open ~/path/to/workspace.code-workspace” • ͋ͷϑΝΠϧͲ͚ͩͬ͜ͳʙͱ୳͕࣌ؒ͢ແବɺίϚϯυύϨοτͰ͙͢ ։͘ vscode
  11. • ghq ͱ gem-src Λ࢖ͬͯɺશ෦खݩʹ clone ◦ fzf Λ࢖ͬͯଈ࠲ʹ։͘ •

    google/codesearch Λ࢖ͬͯେ·͔ͳݕࡧΛͰ͖ΔΑ͏ʹ͢Δ • ͋ΕͳΜ͔ݹ͘Ͷ?ͱ͍͏࣌ʹ౎౓ git pull Λ͢Δͷ͸࣌ؒͷແବͳͷͰ ghq.root ͷԼΛҰؾʹΞοϓσʔτ͢ΔίϚϯυΛ࢓ࣄલʹຖே࣮ߦ ◦ ͦͷ࣌ؒʹ feedly Ͱ֤ࣾͷςοΫϒϩάͱ͔ hackernews ͱ͔શ෦ಡΉ Git ͱ GitHub
  12. • https://github.com/hsbt/hsbt/tree/master/toolbox/libexec ʹࡉ͔͍࣮ߦϓϩ άϥϜΛೖΕ͍ͯΔ • ͲΜͳʹখ͍͞ίʔυͰ΋https://github.com/hsbt/hsbt/tree/master/ sandbox ʹ์ΓࠐΉ ◦ octokit

    ͷॳظԽॲཧͳΜ͔ͩͬͨͳʔɺΛௐ΂Δͷ͸࣌ؒͷແବɺ͜ ͔͜ΒऔΓग़͢ • GitHub copilot ͸͍͢͝ɺશһ࢖͏΂͖ ͦͷଞ
  13. • ಓ۩ͱਓؒΛߟ͑ͨͱ͖ʹɺਓؒͷ࢖͍ํ͕ѱ͍ͱ͍͏ͷͰ͸ͳ͘ɺ࢖͍ ʹ͍͘ಓ۩͕ѱ͍ͱ͍͏ࢥߟͰ͍͘ ◦ ͱ͸ݴͬͯ΋Ϧςϥγʔͱ͔͸஁͑·͚͢ͲͶ... ◦ Ωʔϫʔυ: ਎ମੑɺίϯϰΟϰΟΞϦςΟ • ద౰ʹࢥ͍ු͔΂ͨ৘ใͷஅย͔Β΄͍͠΋ͷΛશ෦ग़Δੈͷதʹͳͬͯ

    ΄͍͠ ◦ ೦͡Δ͚ͩͰṶ͔ΔαʔϏεͰ͖ͯ΄͍͠ ·ͱΊ