2020幎7æ3é± Weekly Report
ð° Topics
twadaããåã®fukabori.fmãäžå¿ã«ã€ã³ãããã®å€ãé±ã§ããã
ãŸãBash-itãvcxsrvã«ããWSL2/Ubuntuç°å¢æŽåãå¿
èŠã§ãð
ã©ã¡ããåäœã§èšäºãæžããã¬ãã«ãæéãèŠã€ããŠæžãããã§ããã
Table of Contents
æžããããš
ä»é±ã¯ãããŸããã
ããã°ã1èšäºæžãããã£ããã
èªãã ããš/èŽããããš
27. è«çåé€ãšã¯äœãïŒã©ã®ãããªè§£æ³ãããã®ãïŒ w/ twada
fukabori.fmã§t-wadaãããDBã®è«çåé€ã«ã€ããŠè©±ãããŠããŸããã
å¿ã«æ®ã£ããã€ã³ãã§ãã
- æèåæ¢ããŠãã¹ãŠã®ããŒãã«ã«åé€ãã©ã°ãä»ããã®ã¯ã¢ã³ããã¿ãŒã³
- ãã¡ã€ã³ã§è«çåé€ãšããèšèãåºãå Žåã¯ãã¡ã€ã³ã¢ãã«ãçã£ãæ¹ããã
ãŸããåé€ãã©ã°ã䜿ãããå Žåã®ä»£æ¿æ¡ã«ã€ããŠã玹ä»ãããŠããŸããã
- ã¹ããŒã¿ã¹ã䜿ã
- ã¢ãŒã«ã€ãããŒãã«ã䜿ã
- UPDATEãDELETEã®ãªãImmutableããã¯ãªèšèšã䜿ã
- é 延ã¬ããªã±ãŒã·ã§ã³ã§UNDOã§ããããã«ãã
3ãš4ã®çºæ³ã¯ãªãã£ãã®ã§å€§å€åèã«ãªããŸããã
28. æè¡éžå®ã®å¯©çŸçŒ(1) w/ twada
åããfukabori.fmã§t-wadaããã話ãããŠããŸããã
è€æ°åã®é·ç·šãšãªã£ãŠããããã®ç¬¬1åã§ãã
ãããã©ã³ãšã³ãžãã¢ã®æ°å°ãªã匷ã¿ã¯ãäžåãåã®èºæããªã¢ã«ã¿ã€ã ã§æããŠããããšã ãããšãããã¬ãŒãºãå°è±¡ã«æ®ã£ãŠããŸãã
- æè¡ãã¬ã³ãã¯åžžã«æ°ãããã®ãåºãããã§ãªã
- äžåãåã«ãã¬ã³ããšãªã£ããã®ãæ¹è¯ãããŠåã³åºçŸãã
- å床ãã¬ã³ããšãªãã«ã¯çç±ããã
- äžåãåã§èª²é¡ã«ãªã£ãŠããããšã解æ¶ãããŠããã±ãŒã¹ãå€ã
- ããã©ã³ã¯äžåãåã«çŸå Žã§ãªã¢ã«ãªçµéšãç©ãã§ããããšãå€ã
- äžåãåãšã®å·®åãèŠæ¥µãããããã®çµéšã¯åŒ·ã¿ã§ãã
ãããŠãå€ãããªãæè¡ã«ã¯å
±éç¹ããããšããããšãã
ãå¶çŽã匷ããã·ã³ãã«ã§ã1ã€ã®å
±éæŠå¿µã«æœè±¡åãããŠããããšããããšã
ãã®ç¶ãã¯æ¯éæ¬ç·šãã芧äžããð€£
æå100äžåã®UberEatsé éå¡ã倧åã«ããããã£ãã²ãšã€ã®ããšã
ã©ã®åéã§ãææãäžãã人ãããããšã¯åãã§ããã
åºæ¬ã«å¿ å®ã«ã¹ãã€ãã¯ã«ç¡é§ãç¡ããããã
Rust for JavaScript Developers
JavaScriptéçºè
åãã®Rust玹ä»èšäºã§ãã
ãšã³ã·ã¹ãã ãä»æ§ãšãJSãšçŽä»ããŠèª¬æãããŠããã®ã§éåžžã«åãããããã§ãã
å人çã«å°è±¡ã«æ®ã£ãŠãããã€ã³ãã
cargo install
ã¯ã°ããŒãã«ã€ã³ã¹ããŒã«ãªã®ã§cargo-edit
ã䜿ã- ã¿ã¹ã¯ã©ã³ããŒã¯
Make
ã䜿ã cargo-watch
- constã¯ã³ã³ãã€ã«æã«å®æ°ãšãªã
Tauri
ããã³ããšã³ããHTML/JS/CSSãããã¯ãšã³ããRustã§äœããã¹ã¯ããããã©ãããã©ãŒã ã®ãã¬ãŒã ã¯ãŒã¯ã§ãã
TypeScriptããµããŒããããã®ã§ããã°éåžžã«æ°ã«ãªããããã¯ãã§ãã
Electronã®åŸéåè£ã®1ã€ãšããŠæåŸ
ã§ãããããããŸããã
åœåã®ããã»ã¹
æé»ç¥ãšãããããšãå€ãåœåã®ããã»ã¹ã詳ããæžãããŠããŸããå¿ èŠð
ç¹ã«ä»¥äžã®æã奜ãã§ãã
èšèšãšã¯ãèªåãèŠãŠããå Žæãããã®ãã¹ããæžãã®ãã©ãã»ã©å€§å€ã ã£ãããã§ãååãå€ããããšã§ãã®æ°ä»ããæžããšããã«ãŒãã§ããã(éåžžããã¯ãæ£ããããšããããååã«ä¿®æ£ããã¹ãããã§ãã)
æ¬æã¯ããªãé·ãã§ãããæåŸã®æ¹ã§DDDã®è©±ãåºãŠããŠãã³ã·ã§ã³äžãããŸãâºïž
ãååãã€ããããšãããã°ã©ãã³ã°ã®7å²ããã£ãã·ã¥ã2å²ã§ããšã¯ãªãã±ããšã¯èšã£ããã®ã§ãååã ãèŠãã°ã³ãŒãã®å質ãåãããšããã®ãçŽåŸã§ããð
è©Šããããš
ãGitHubããŠãŒã¶ã«çŽã¥ãREADME
ãŠãŒã¶åãšåããªããžããªãäœæããŠREADME.md
ãæžããšãããããŒãžã«è¡šç€ºãããæ©èœãè©ŠããŸããã
ãããªæãã«è¡šç€ºãããŸãã
ãRustãcargo-watch
Rustã®ã³ãŒããå€æŽãããšãèªåã§ãã«ããåŠçãå®è¡ããŠãããŸãã
cargo install cargo-watch
ã§ã€ã³ã¹ããŒã«ããå¿
èŠããããŸãã
å€æŽæã«ãã«ãããŠãã®ãŸãŸå®è¡ããã³ãã³ãã§ãã
-x
ãªãã·ã§ã³ã§cargoã³ãã³ããæå®ããŸãã
cargo watch -x run
ãTypeScriptãmockdate
çŸåšæ¥æãä»»æã®å€ã«æå®ã§ããMockãäœæã§ããŸãã
dayjsã®äœè ãæ¡å ããŠããã®ã§äœ¿ã£ãŠã¿ãŸãããã·ã³ãã«ã§äŸ¿å©ã§ããã
調ã¹ãããš
ãGitãå ¬ééµã®ãã©ãŒããããäžæ£ãªèŠå
å€åãGitãããŒãžã§ã³ã¢ããããŠãããã®èŠåãåºãããã«ãªããŸããã
Gitã®åäœã«ã¯åé¡ãããŸããã§ããã
load pubkey "/c/Users/syoum/.ssh/id_rsa_github": invalid format
ããäžåºŠssh-keygen
ã§ããŒãäœæ/ç»é²ããªããããæ¶ããŸããã
ç§å¯éµã®ããããšããã¿ãå€ãã£ãŠããã®ã§ããã圱é¿ããŠããã
- -----BEGIN RSA PRIVATE KEY-----
+ -----BEGIN OPENSSH PRIVATE KEY-----
- -----END RSA PRIVATE KEY-----
+ -----END OPENSSH PRIVATE KEY-----
以äžã®èšäºã§ç°¡åã«èª¬æãããŠããŸããã®ã§ãæ°ã«ãªãæ¹ã¯ãã¡ããã©ããã
æŽåããããš
Bash-it
Bash-itã¯Bashã³ãã¥ããã£ãæäŸããBashã®ã³ãã³ã/ã¹ã¯ãªãã矀ã§ãã
äž»ã«ããã³ããã®èŠãç®/æåãå€æŽããç®çã§ãã¡ããå°å
¥ããŸããã
READMEã®æé ã«æ²¿ããããAnsibleã®roleãäœããŸããã
- name: "Clone"
git:
repo: https://github.com/Bash-it/bash-it.git
dest: ~/.bash_it
depth: 1
- name: Install
shell: ~/.bash_it/install.sh
~/bash_it/install.shãå®è¡ãããš.bashrcãäžæžããããã®ã§æ³šæ
ã€ã³ã¹ããŒã«ããããšæ¢åã®.bashrc
ãå®å
šã«äžæžããããŸãã
è¿œèšã§ã¯ãããŸããã
äžæžãåã®ãã¡ã€ã«ã¯~/.bashrc.bak
ãšããŠä¿åãããŠããŸãã
/bashrc
ãã«ã¹ã¿ãã€ãºããŠããå Žåã¯ã€ã³ã¹ããŒã«åŸã«èšå®ãããŒãžããŸãããã
ããã³ããããŒãã¯æ¢åã®ãã®ãåèã«èªäœããŸããã
ã³ãŒããæŽåããããå
¬éããäºå®ã§ãã
WSL2ã®UbuntuããIntelliJ IDEAã䜿ã
以äžã®èšäºã§ã€ã³ã¹ããŒã«ããvcxsrvã䜿ã£ãŠãIntelliJ IDEAããŠã£ã³ããŠã§ç«ã¡äžããŸãã
ãã©ã³ãã®ã€ã³ã¹ããŒã«ãªã©ã¯å¿
èŠã§ããæ®éã«åããŸããã
ãã ãæ¥æ¬èªå
¥åãã§ããªãã®ã§å¯Ÿçãå¿
èŠã§ãã
ã¹ããããGmailãã¢ã³ã€ã³ã¹ããŒã«
以äžã®èšäºã«åœ±é¿ãåããŠãã¹ããŒããã©ã³ããGMailãæ¶ããŸããã
çç±ã¯ä»¥äžã®éãã§ãã
- Gmailã§æ¥ã è¿ä¿¡ ãå¿ èŠãªçšäºã¯ãªã
- Gmailã§æ¥ã é£çµ¡ ãå¿ èŠãªçšäºã¯ãªã
æ¥ã«å¿ èŠã«ãªã£ãå Žåã¯ãiPadãPCã§éä¿¡ããã°ããããšã
ä»é±ã®ãªãªãŒã¹
Togowl v1.16.3
æéå€æŽã«ã¬ã³ããŒã®éå§ææ¥ãæææ¥ã«å€æŽ
TodoistãäŒç€Ÿã®ã«ã¬ã³ããŒãæææ¥ãªã®ã§ããããŸããã
Owlelia v0.11.0 ïœ v0.12.0
datetimeã¢ãžã¥ãŒã«ã®è¿œå
Owleliaã®ValueObject
ãå®è£
ããæ¥ä»åã®voãè¿œå ããŸããã
å
éšã§ã¯dayjsã䜿ã£ãèãã©ãããŒãšãªã£ãŠããŸãã
ãã¡ã€ã³é§åéçºãããäžã§ãæ¥ä»åã¯ã»ãŒå¿
ãç»å Žããããå梱ããããšã«ããŸããã
DDDã®ã³ã¢ã§äœ¿ãã¢ãžã¥ãŒã«ã§ã¯ãããŸãããäŸå€çã«ã
ãµã³ãã«ã³ãŒãã§ãã
import { DateTime } from "owlelia";
console.log(DateTime.now().rfc3339);
// -> 2020-07-18T11:50:11+09:00
console.log(DateTime.of("2020-01-01").rfc3339);
// -> 2020-01-01T00:00:00+09:00
console.log(DateTime.of("2020/01/01").plusDays(3).rfc3339);
// -> 2020-01-04T00:00:00+09:00
console.log(
DateTime.of("2020-01-15 13:00:00").between(
DateTime.of("2020-01-15 12:00:00"),
DateTime.of("2020-01-15 14:00:00"),
)
);
// -> true
console.log(
DateTime.of("2020-01-15 13:00:00").between(
DateTime.of("2020-01-15 13:00:00"),
DateTime.of("2020-01-15 14:00:00"),
{
includeBegin: false,
includeEnd: false,
ignoreTime: false,
}
)
);
// -> false
console.log(
DateTime.of("2020-01-15 13:00:00").between(
DateTime.of("2020-01-15 13:00:00"),
DateTime.of("2020-01-15 14:00:00"),
{
includeBegin: true,
includeEnd: false,
ignoreTime: false,
}
)
);
// -> true
ä»åŸãã¹ãã±ãŒã¹ã«äžéãè¿œå ããŠããã®ã§ã詳ããã¯ãã¡ããã芧äžããã
ãã®ä»
iPad Proã®æšæºã¡ã¢ã¯æ匷ãªã®ã§ã¯ãªãã
iPadã§Apple Pencilã䜿ã£ãã¡ã¢ããŒã«ã¯è²ã
ãããŸãã
ç§ã以äžã®ããŒã«ãç¶æ³ã«å¿ããŠäœ¿ãåããŠããŸããã
ããããæè¿ã«ãªã£ãŠãã®äžã®1ã€ã䜿ãããšãå€ããªããŸããã
ããã¯ã¡ã¢ã§ããããªã€ã³ã¹ããŒã«ãããŠããã¢ããªã§ãã
ä»ã®ããŒã«ã«æ¯ã¹ãŠæ©èœã¯å£ããŸãããéã«ãã®ã·ã³ãã«ããæ倧ã®é
åã§ãã
ãã¯ãã¡ã¢ãããã®ãæ°è»œã«çŽæçã«ãµããšäœ¿ããªããŠãããŸããã
ç§ãã¡ã¢ãæ°ã«å ¥ã£ãŠããç¹ã¯ä»¥äž9ç¹ã§ãã
- ããã¯ç»é¢ã§Apple Pencilãããã«ã¿ãããããšããã«äœ¿ãã
- ãšã³ããã®æžãå¿å°ããã
- ããŒã«ãããããªã·ã£ã¬
- ãã³ã®åŸãã«å¿ããŠäœ¿ãå¿å°ãå€ãã.. ç¹ã«ãšã³ãããšæ¶ããŽã ã¯å¿ èŠ!!
- çŽã«æžããŠãããšé¯èŠããã»ã©é 延ããã³å ã®ãºã¬ããªã
- æšªå¹ ã¯åºå®ã ã瞊ã®ãµã€ãºã¯äŒžã°ãã (ç¡é?)
- ãã³ã°ã¿ããããããšæç»é åå šäœãç»åãšããŠã³ããŒã§ãã
- èªç±ç¯å²ãéžæããŠç§»å/è€è£œ/ã³ããŒãã§ãã
- Apple Pencil以å€åå¿ããªã
äžæ¹ã埮åŠãªéšåããããŸãã
- 1ç»é¢ã«æ²¢å±±ã®æå(ãã¯ã¿ãŒããŒã¿)ãæžããšçªç¶éããªã
- ãã£ã³ãã¹ã®æ¡å€§/çž®å°ããã¯ã¿ãŒããŒã¿ã®æ¡å€§/çž®å°ãã§ããªã
- å³åœ¢æç»ãªã©ã¯ã§ããªã
- æšªå¹ ãåºå®
- ç»åãšææžããå ±åãããã®ãé£ãã (ç»åããŒã¿ã«æžã蟌ã¿ã¯ã§ãã)
- å ±åç·šéãã§ããªã
ãšã¯ããåé¡ã«ãªããªãã±ãŒã¹ãå€ãã®ã§ããã®å Žåã¯ä»ã®ããŒã«ã䜿ãã°ååã§ãã
çŸå®äžçã®A4çšçŽã«ã¡ã¢ãæžãã®ãšåãæèŠã§äœ¿ããã®ãæ°æã¡ããã§ããð
ã¡ã¢ã§ã©ãã«æžããŠã³ããŒããç»åãSlackã§å ±æ..ããããŸãð