"tree -J"コマンドは無効なJsonを返します。

私のコンピュータでコマンドを実行しましたが、tree -Jこれが提供した出力の一部です。

                {
                    "type": "file",
                    "name": "ca-certificates.conf"
                },
                {
                    "type": "file",
                    "name": "ca-certificates.conf.dpkg-old"
                },
                {
                    "type": "directory",
                    "name": "chatscripts"
                } {
                    "error": "error opening dir"
                },
                {
                    "type": "directory",
                    "name": "chromium",
                    "contents": [{
                        "type": "directory",
                        "name": "native-messaging-hosts"
                    }]
                }

その「エラー」ノードを見てください。有効なJsonではないようです(,aが見つかりません)。この種のエラーが表示されないようにするにはどうすればよいですか?

使用v2.0.2

ベストアンサー1

これは既知のバグです。。明らかに修正されたようです。昨日、2023年5月31日。

どこにいるのかわかりませんでした。https://gitlab.com/OldManProgrammer/unix-tree/-/commit/84fa3ddff51b30835a0f9c4a9e4c9225970f9aff確定したが、それはあなたとスティーブ・ベイカー

おすすめ記事