date 명령을 사용하여 다음 주를 인쇄하는 방법은 무엇입니까?
date +"This is week: %U of %Y, Sprint: %y(W%U-%U)"
출력은
This is week: 04 of 2017, Sprint: 17(W04-05)
바꾸다
This is week: 04 of 2017, Sprint: 17(W04-04)
답변1
GNU 사용 date
:
date +"This is week: %U of %Y, Sprint: %y(W%U-$(date -d 'now + 7 days' +%U))"
또는:
date +"This is week: %U of %Y, Sprint: %y(W%U-$(date -d 'next week 12:00' +%U))"