python / python/python-docs-zh-tw

Adopt `potodo` in Makefile

Đang mở
#130 1 bình luận 3 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

enhancement good first issue
Ngôn ngữ chính
Python
Star
282
Fork
226
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

I found a tool named potodo that provides same functionalities with part of our current Makefile commands but has better format. We can consider adopting this tool in our Makefile (or even storing the output as a file and updating it whenever a PR is merged).

  • Listing untranslated files

    • make todo
      > make todo           
      for file in *.po */*.po; do echo $(msgattrib --untranslated $file | grep ^msgid | sed 1d | wc -l ) $file; done | grep -v ^0 | sort -gr
      929 library/stdtypes.po
      790 library/os.po
      660 whatsnew/3.3.po
      633 library/curses.po
      577 c-api/typeobj.po
      555 whatsnew/3.7.po
      554 library/datetime.po
      539 whatsnew/3.5.po
      539 whatsnew/2.6.po
      518 whatsnew/3.2.po
      517 whatsnew/3.6.po
      ...
      
    • potodo
      > potodo
      # extending (3.17% done)
      
      - building.po                      0 /  23 (  0.0% translated)
      - embedding.po                     1 /  45 (  2.0% translated)
      - extending.po                     2 / 158 (  1.0% translated)
      - newtypes.po                      0 /  91 (  0.0% translated)
      - newtypes_tutorial.po             0 / 123 (  0.0% translated)
      - windows.po                       0 /  21 (  0.0% translated)
      
      
      # faq (10.27% done)
      
      - design.po                       13 / 141 (  9.0% translated), 2 fuzzy
      - extending.po                     0 /  60 (  0.0% translated)
      - general.po                      33 /  91 ( 36.0% translated)
      - gui.po                           2 /  17 ( 11.0% translated)
      - library.po                      11 / 142 (  7.0% translated)
      - programming.po                  13 / 372 (  3.0% translated)
      - windows.po                       3 /  47 (  6.0% translated)
      ...
      
  • Listing fuzzy entries

    • make fuzzy
      > make fuzzy
      for file in *.po */*.po; do echo $(msgattrib --only-fuzzy --no-obsolete "$file" | grep -c '#, fuzzy') $file; done | grep -v ^0 | sort -gr
      163 library/functions.po
      8 library/statistics.po
      5 c-api/function.po
      5 c-api/datetime.po
      4 library/unittest.po
      3 library/heapq.po
      ...
      
    • potodo --only-fuzzy
      > potodo -f
      # c-api (5.20% done)
      
      - datetime.po                      8 /  41 ( 19.0% translated), 5 fuzzy
      - dict.po                          5 /  30 ( 16.0% translated), 1 fuzzy
      - function.po                      4 /  18 ( 22.0% translated), 5 fuzzy
      - unicode.po                       5 / 334 (  1.0% translated), 1 fuzzy
      
      
      # distutils (0.00% done)
      
      - examples.po                      0 /  46 (  0.0% translated), 1 fuzzy
      
      
      # faq (9.22% done)
      
      - design.po                       13 / 141 (  9.0% translated), 2 fuzzy
      ...
      
  • Get overall progress

    • make progress
      > make progress
      4.4%
      
    • potodo | tail -n2 | head -n1 | cut -c 10- | sed 's/[%].*$/%/g'
      > potodo | tail -n2 | head -n1 | cut -c 10- |  sed 's/[%].*$/%/g'
      4.31%
      

Hướng dẫn đóng góp

Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Hướng nghiên cứu

Bắt đầu với các lệnh trong Makefile của repository dành cho todo, fuzzy và progress, sau đó so sánh đầu ra của chúng với các ví dụ potodo được ghi lại trong issue này. Kiểm tra cách potodo sẽ được gọi trong Makefile và liệu đầu ra của nó nên vẫn là kết quả của một lệnh hay được lưu thành một tệp. Hoàn thành khi các lệnh trạng thái bản dịch được chọn cung cấp các kết quả theo kiểu potodo như dự kiến.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Lĩnh vực
documentation, tooling
Loại issue
Tính năng
Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Khá rõ ràng
Mức phù hợp với người mới
35/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.