らいふうっどの閑話休題

興味のあることをゆる~く書いていく

Angular Document Transration Begining

Angular ドキュメント翻訳の事始め

この記事は、Angular Advent Calendar 2017の23日目の記事です。
this report is Angular Advent Calendar 2017, day 23.

Angular ドキュメントの翻訳について紹介します。
I will introduce translation of Angular documents.  


まず最初に見る所 / First place to see

angular/angular-ja の README.md を読みましょう。
Let's read README.md of angular / angular-ja.

基本的な事は、全てここに記載されています。
All the basic things are listed here.


実施環境 / Implementation environment

npm, node, yarn, Tyepscript, Angular cli のバージョンは、下記の通りです。
npm, node, yarn, Tyepscript, Angular cli version is following.




セットアップ / Set Up

  1. リポジトリのクローン / clone of repository
        
          ➜  git clone git@github.com:angular/angular-ja.git  # From angular/angular-ja
          or 
          ➜  git clone https://github.com/UserName/angular-ja.git # From Fork repository
        
      
    ※自分は、先にフォークしてからクローンしました。
    ※I first forked and cloned it.
  2. angular/angularリポジトリのダウンロード download of angular/angular repository
  3. npm インストール / npm install
        
          ➜  angular-ja git:(master) ✗ npm i  # npm install
        
      

README.md の手順通りです。
※npm インストールを追記しています。 / add steps npm install.


ローカルでのビルド / Local Building

  
    ➜  angular-ja git:(master) ./build.sh
  
 

README.md の手順通りです。
※npm インストールを追記しています。 / add steps npm install.


ローカルでのビルドで躓いた事 / point of failed for Local Building

  • node のバージョン / node's version 当初 v8.4.0 でしたが、ビルドする際に、エラーが発生する為、バージョンを v6.9.5 にしました。
    at first v8.4.0, version down to v6.9.5. beacause build error had occured.
  • yarn のバージョン / yarn's version
    yarn のバージョンをv1.3.2にしました。
    yarn のバージョン v1.0.0以下だと、ビルドエラーが発生する為です。
    Because yarn version v1.0.0 or less, a build error had occured.
  • Tyepscript のバージョン / Tyepscript's version
    Tyepscript のバージョンをv2.4.2にしました。 下記警告が、出力されますが問題ありません。
    The following warning is output, but there is no problem.
  • SSHキーに誤りがありました。 / wrong SSH key
    githubSSHキーをさくらVSPサーバーのSSHキーに上書きしていた為、
    下記エラーが発生しました。
    Follwong Error had occured.
    Beacuse SSH key of github had overwite by SSH key of SAKURA VPS Server
          
            ➜  angular-ja git:(master) git submodule update --init
            Submodule 'origin' (git@github.com:angular/angular.git) registered for path 'origin'
            Cloning into '/Users/UserName/work/angular-ja/origin'...
            git@github.com: Permission denied (publickey).
            fatal: Could not read from remote repository.
          
        

    Please make sure you have the correct access rights and the repository exists.
    fatal: clone of 'git@github.com:angular/angular.git' into submodule path '/Users/UserName/work/angular-ja/origin' failed


翻訳作業 / Translation Work

  1. 翻訳宣言のイシューを作成する / Creating New Issue
  2. 翻訳で置き換えたいファイルを aio-ja ディレクトリにコピーする Copy the file you want to replace with the translation into the aio-ja directory

    今回の場合は、既に guide/testing.md が aio-ja ディレクトリにありました。
    In this case, you already have guide / testing.md in the aio-ja directory.

  3. 翻訳します / Translate
  4. プルリクエストを作成します / Create Pull Request ※この記事では、プルリクエストを作成していません。
    ※事前にフォークしたリポジトリからプルリクエストしても同じです。



ローカルでの確認 / Local Confirm

  
  ➜  angular-ja git:(master) ✗ cd .tmp/aio
  ➜  aio git:(6e8e3bd) yarn serve-and-sync
  



まとめ / Summary
  今回は主に翻訳に着手するまでの過程で、自分が躓いた点をまとめました。
This time I mainly compiled the points I gained in the process until I started translating.
記事作成中に ng-japan の Slack の #traslation で、こんなポストがありました。
というわけで、慌てずに年末年始で翻訳する準備をしてみては如何でしょうか?
so, What do not you try getting ready to translate?
明日は、 @albatrosary さんです!
Tomorrow is @albatrosary !


追記 / Additional notes
  後日(12/26)に更新のポストが有りました。 There was an update post at (12/26) at a later date. 翻訳環境を更新しました。 I updated the translation environment.  
npm, node, yarn, Tyepscript, Angular cli のバージョンは、下記の通りです。 npm, node, yarn, Tyepscript, Angular cli version is following.

リポジトリの更新は、下記状態になります。 Updating the repository is as follows.


yarn's memo

            yarn のバージョンアップで気付いたので、メモ

As I noticed in version up of yarn


きっかけ / Trigger

yarn の最新バージョンを知ったので、バージョンアップしてみたら、更新されなかった。 Since I knew the latest version of yarn, I did not update it as I upgraded it.

➜ ~ yarn -v

yarn v1.2.1 ==> v1.3.2 になるはずだった It was supposed to be yarn v1.2.1 ==> v1.3.2


試行錯誤 / Trial And Error

➜ ~ npm install yarn -g /Users/Account/.nodebrew/node/v8.4.0/bin/yarnpkg -> /Users/Account/.nodebrew/node/v8.4.0/lib/node_modules/yarn/bin/yarn.js /Users/Account/.nodebrew/node/v8.4.0/bin/yarn -> /Users/Account/.nodebrew/node/v8.4.0/lib/node_modules/yarn/bin/yarn.js + yarn@1.3.2 added 1 package in 1.842s ➜ ~ yarn -v 1.2.1 ➜ ~
バージョンアップされない。 / Not upgraded.
➜ ~ brew uninstall yarn Uninstalling /usr/local/Cellar/yarn/1.3.2... (14 files, 3.9MB) ➜ ~ brew install yarn Updating Homebrew... ==> Downloading https://yarnpkg.com/downloads/1.3.2/yarn-v1.3.2.tar.gz 🍺 /usr/local/Cellar/yarn/1.3.2: 14 files, 3.9MB, built in 1 second ➜ ~
バージョンアップされない。 / Not upgraded.


原因 / Cause

.yarn, .yarnrc が古いバージョンを示していた模様。 It seems that .yarn, .yarnrc indicated the old version.



対策 / CounterPlan

➜ ~ mv .yarn back.yarn ➜ ~ mv .yarnrc back.yarnrc

上記コマンド実行後、確認したら直った。 After execution of the above command, I fixed it after confirming it.


Comparing browser performance on my PC

            Firefox Quantum がリリースされたので、また恒例のパフォーマンスチェックをしようと思います。

Since the Firefox Quantum has been released, I will also do an annual performance check.


any browser history / 各ブラウザのまとめ
  もう一度、レンダリングエンジンとか気になったので、興味のある範囲で表にまとめてみました。
Again, since I became concerned with the rendering engine, I tried putting it in a table in the area of interest.
歴史的なものは、こちらを参照「Webブラウザの歴史 - フォクすけの Firefox 情報局
Historical ones, see here "History of Web Browser - Fokusuke Firefox Information Office"  

PC specs / パソコンのスペック
  1. case macOS / macOS の場合
  2. case Ubuntu 17.10 / Ubuntu 17.10 の場合
  3. case Windows 10 / Windows 10 の場合
 

macOS bench score / macOS での各ブラウザのベンチスコア
  Browser Version / ブラウザバージョン case Chrome / Chrome の場合

case Firefox / Firefox の場合

case Kinza / Kinza の場合

case Safari / Safari の場合

case Vivaldi / Vivaldi の場合

mac's bench score / mac での各ブラウザのベンチスコア

  1. case Chrome / Chrome の場合

  2. case Firefox / Firefox の場合

  3. case Kinza / Kinza の場合
  4. case Safari / Safari の場合

  5. case Vivaldi / Vivaldi の場合


Ubuntu 17.10's bench score / Ubuntu 17.10 での各ブラウザのベンチスコア
  Browser Version / ブラウザバージョン case Chrome / Chrome の場合 case Firefox / Firefox の場合

case Vivaldi / Vivaldi の場合

Ubuntu 17.10's bench score / Ubuntu 17.10 での各ブラウザのベンチスコア

  1. case Chrome / Chrome の場合
  2. case Firefox / Firefox の場合

  3. case Vivaldi / Vivaldi の場合


Windows 10's bench score / Windows 10 での各ブラウザのベンチスコア
  Browser Version / ブラウザバージョン case Chrome / Chrome の場合

case edge / edge の場合 case IE11 / IE11 の場合 case Firefox / Firefox の場合

case Kinza / Kinza の場合 case Vivaldi / Vivaldi の場合

Windows 10's bench score / Windows 10 での各ブラウザのベンチスコア

  1. case Chrome / Chrome の場合

  2. case edge / edge の場合
  3. case Firefox / Firefox の場合

  4. case IE11 / IE11 の場合
  5. case Kinza / Kinza の場合
  6. case Vivaldi / Vivaldi の場合


まとめ
  測定した結果、下記の通りになりました。 以前測定に使っていた OORTONLINE.GL が使えなくなったのは残念です
As a result of the measurement, it became as follows.
It is a pity that OORTONLINE.GL used for measurement was no longer usable

 
Ubuntu 17.10
Windows 10
27654
26934
17351
Chrome Canary
31442
18640
edge
17086
26217
24269
18351
Firefox Developer Edition
26850
24269
18289
Firefox Nightly
25574
24756
17307
IE11
9447
Kinza
29703
16679
29281
Safari Technology Preview
31359
27210
25065
15914
  あくまでも自分所有マシンの環境ですので、他の PC や OS では、また別の結果が出ると思います。
Myself am the environment of the property machine to the end, so I think the different result is in again by other PC and OS.

benchmarck site list / 評価サイト一覧 「Windows 10」向け最強ブラウザ決定戦--各ベンチマークの結果は? より引用



Hacking a valence.xpi - Prologue

            <div class="headline-m">目次</div>


きっかけ / Trigger

CHRIMEN Open Hardware コミュニティの活動で、B2G OS 向けの開発ツール WebIDE での開発に支障が出ることに気が付きました。
In the activities of the CHRIMEN Open Hardware community, I noticed that development with WebIIDE, a development tool for B2G OS, was hindered.
具体的には、下記操作ができなくなっていました。

  • プロジェクト作成後、プロジェクトツリーが、見れなくなっている
    After creating the project, the project tree can not be seen
  • B2G OS へアプリをインストール出来なくなっている
    You can not install applications to B2G OS

Firefox ver.55以降で、使用できなくなっているようです。
調べた所、下記情報が見つかりました。
It seems that it can not be used with Firefox ver.55 or later.
After examining, the following information was found.

Remove WebIDE https://bugzilla.mozilla.org/show_bug.cgi?id=1314811
WebIDE project tree and Edit area didn't display. https://bugzilla.mozilla.org/show_bug.cgi?id=1391641
対応策ですが、下記の通りです。



目的 / Purpose

このブログでは、下記項目を目的にハックしていきます。
In this blog, I will hack for the following items.

  • valence.xpiの仕組みを知ること
    Knowing the mechanism of valence.xpi
  • WebIDEの後継の拡張Extensionの作成
    Creation of extended extension for successor to WebIDE

valence.xpi は、下記リンクからダウンロード出来ます。
valence.xpi will be able to Download following links.
linux64:http://archive.mozilla.org/pub/labs/valence/linux64/
ma64:http://archive.mozilla.org/pub/labs/valence/mac64/
win32:http://archive.mozilla.org/pub/labs/valence/win32/


githubリポジトリは、こちらです。
The repository of github is here.
https://github.com/mozilla/valence


ハックしている時のバージョンは、 0.3.8 です。
The version when hacking is 0.3.8.


Folder Compose / フォルダ構成

valence.xpi ファイル を解凍したフォルダ構成は、下図のとおりです。
The configuration of the folder that unzipped the valence.xpi file is shown below.
各 OS とも同じフォルダ構成です。
Each OS has the same folder Compose.



差分を掛けてみた所、install.rdf ファイルの URI が、 OS 毎に異なっていました。
次回は、各ファイルはディレクトリ別にハックしていきたいと思います。
When I multiplied the difference, the URI of the install.rdf file was different for each OS.
Next time, I would like to hack each file by directory.




Correspondence for Windows10 Upgrade Error tips

            Correspondence for Windows10 Upgrade Error tips / Windows10 アップグレードエラー時の tips
Index / 目次
a Trigger / きっかけ
  when Windows10 Insider Preview upgrade failed on Build 16215 to 16223, because i wirte memo.
Windows10 Insider Preview のアップグレード ビルド 16215 から 16223 へ失敗をしたので、メモ。



The cause / 原因
  upgrade failed on Build 16215 to 16223 several times, i'll ckeck it.
ビルド 16215 から 16223 へ数回に失敗したので、調べてみることに。

i had finded error No 0x80073712 .
エラー番号 0x80073712を見つけました。

may be system file damage.
おそらくシステムファイルが破損しているようです。


a resolve / 解決
  Following correspondence was done.
下記対応をしました。
type cmd in cortana area.
コルタの入力欄に「cmd」と入力


excute command prompt administrator mode.
コマンドプロンプトを管理者権限で実行


type [DISM.exe /Online /Cleanup-image /Restorehealth, press enter key.
「DISM.exe /Online /Cleanup-image /Restorehealth」と入力し、Enter キーを押します。
  
    Microsoft Windows [Version 10.0.16232.1000]
    (c) 2017 Microsoft Corporation. All rights reserved.

    C:\WINDOWS\system32>DISM.exe /Online /Cleanup-image /Restorehealth
  
just in case, A cleanup of a disk => A cleanup of a system is performed.
念の為、ディスクのクリーンアップ => システムのクリーンアップを行います
The place upgraded once again has been normally ended safely.
再度アップグレードを実施した所、無事正常終了しました。

Just Build 16232.
ビルド 16232 になりました。



Now Browser Performance Check

新しいブラウザ「Kinza」を知ったので、前回の「坊主五厘がVivaldiの性能を他のブラウザと比較するようです。」に引き続き、今時のブラウザのパフォーマンスを計測したいと思います。
i had known new browser is Kinza, After last time [ 坊主五厘がVivaldiの性能を他のブラウザと比較するようです。 ] , i'll be checked any browser performance.


any browser history / 各ブラウザのまとめ
  もう一度、レンダリングエンジンとか気になったので、興味のある範囲で表にまとめてみた 歴史的なものは、こちらを参照「Webブラウザの歴史 - フォクすけの Firefox 情報局

PC specs / パソコンのスペック
 
  1. case macOS / macOS の場合
  2. case Ubuntu 17.04 / Ubuntu 17.04 の場合

  3. case Windows 10 / Windows 10 の場合


mac's bench score / mac での各ブラウザのベンチスコア
  Browser Version / ブラウザバージョン

Build16179
Build16179

mac's bench score / mac での各ブラウザのベンチスコア

  1. case Chrome / Chrome の場合
  2. case Firefox / Firefox の場合
  3. case Kinza / Kinza の場合
  4. case Safari / Safari の場合
  5. case Vivaldi / Vivaldi の場合


Ubuntu 17.04's bench score / Ubuntu 17.04 での各ブラウザのベンチスコア
  Browser Version / ブラウザバージョン

Ubuntu 17.04's bench score / Ubuntu 17.04 での各ブラウザのベンチスコア

  1. case Chrome / Chrome の場合
  2. case Firefox / Firefox の場合
  3. case Vivaldi / Vivaldi の場合


Windows 10's bench score / Windows 10 での各ブラウザのベンチスコア
  Browser Version / ブラウザバージョン

Windows 10's bench score / Windows 10 での各ブラウザのベンチスコア

  1. case Chrome / Chrome の場合
  2. case edge / edge の場合
  3. case Firefox / Firefox の場合
  4. case Kinza / Kinza の場合
  5. case Vivaldi / Vivaldi の場合


まとめ
 
 
edge
Kinza
mac
8740 518
-
6910 470
8650 519
8150 409
8740 518
Ubuntu 16.04
3230 489
-
2810 470
-
-
3200 516
Windows 10
9670 518
8090 473
5430 470
9360 519
-
8960 518
  あくまでも自分所有マシンの環境ですので、他の PC や OS では、また別の結果が出ると思います。
Myself am the environment of the property machine to the end, so I think the different result is in again by other PC and OS.

benchmarck site list / 評価サイト一覧 「Windows 10」向け最強ブラウザ決定戦--各ベンチマークの結果は? より引用


Windows10 Load reduction Tips


Windows10 Load reduction Tips / Windwos10 負荷軽減 tips

Index / 目次
a Trigger / きっかけ
  前回「坊主五輪がようやくWindows10 Build14393に落ち着けたようです。からしばらくして やはり気になる事が出てきました。
症状は、CPU ファンの唸り音とディスクアクセス、Firefox のレスポンスの悪さです。

As I thought, A worrisome thing has come out as expected.
It is CPU fan noise, Disk Access, Firefox was Bad Response.


wuauclt.exe is cleaning / wuauclt.exe をきれいにする
  タスクマネージャーやリソースモニターをチェックした所、wuauclt.exe が活発な活動をしていました
調査をして、次の記事の内容を見つけ、実施しました
i had checked task manager and resource monitor, wuauclt.exe was activity very much.
i had reserached, i had found to following context and it was put into effect.
windows起動時にPCが重たい、『wuauclt.exe』をきれいにする。Windows7・Windows VISTA 編


Windwos Search Service stopped / Windwos Search サービスの停止
  Build 16179 にバージョンアップされた時にいつも施していなかった対策を思い出しました。
それは、Windows search サービスを停止することです。

i remember that setting when Windows update Build 16179.
it is Windwos Search Service stopped.

コントロールパネルを開きます。
Contorol Pannel is Opened.

管理ツールを開きます。
Admin Tools is Opened.

サービスを開きます。
service is Opened.
Windows search サービスを無効、停止します。
Windows search service was disabled and stopped.

また、この設定は新しいビルドになる度に元に戻ります。
and more, this setting was reset when windows new build.


Firefox response / Firefox のレスポンス
  まず最初にFirefox のリフレッシュをやってみました。
at first, i had tryed Firefox refresh.

バーガーボタンをクリックし、「?」をクリックします
Bager button was clicked, [?] was clicked.
次にトラブルシューティング情報をクリックします。
next, trouble shooting infomation was clicked.

Firefox をリフレッシュ」をクリックしましたが、効果がありませんでした。
when [ Firefox is refresh ] was clicked, It was ineffective.

次に下記リンク先の手順を施したら、効果が出ました。
Next if a procedure ahead of following link was done, I produced the good result.

windows10でFirefox使用中、動作が遅いときの対処


CPU fan noise / CPU ファンの唸り音
  PC の 外装を外したら、中はホコリまみれでした。
i had opened desktop pc, inside was covered with dust.

ダストブロワーをかけて、ホコリを取り除いたら、CPU ファンの音は静かになりました。
If a dust blower was bet and dust was taken, the tone of the CPU fan became quiet.

皆さん、パソコンはこまめに掃除しましょう
I'll clean everyone and a PC briskly.


Summary / まとめ
  ディスクアクセスの対処は分からずじまいでしたが、今回はこれで良しとします。
i don't know a problem of Disk Access, i assume that this is OK this time.

※2017/04/29 時点での自分が得た知見です。
所有している PC やインストール手順が異なる場合
性能や結果に差が出る事は予めご承知置き下さい

また情報や知見を得たら、書きたいと思います。

※i had get a know how at 2017/04/29.
When it's different in possessed PC and installation procedure.
Agreement puts that the difference goes out to the performance and a result beforehand, and can I have it?

If I get information and knowledge again, I'd like to write it.
お試しTips
関連記事