macOS Homebrew错误汇编(踩坑指南)

事情的起因是升级了macOS,然后homebrew就各种报错。

Error: Can't create update lock in /usr/local/var/homebrew/locks!
Fix permissions by running:
sudo chown -R $(whoami) /usr/local/var/homebrew
Traceback (most recent call last):
11: from /usr/local/Homebrew/Library/Homebrew/brew.rb:31:in `<main>'
10: from /usr/local/Homebrew/Library/Homebrew/brew.rb:31:in `require_relative'
9: from /usr/local/Homebrew/Library/Homebrew/global.rb:80:in `<top (required)>'
8: from /usr/local/Homebrew/Library/Homebrew/vendor/portable-ruby/2.6.3_2/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
7: from /usr/local/Homebrew/Library/Homebrew/vendor/portable-ruby/2.6.3_2/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
6: from /usr/local/Homebrew/Library/Homebrew/os.rb:7:in `<top (required)>'
5: from /usr/local/Homebrew/Library/Homebrew/os.rb:43:in `<module:OS>'
4: from /usr/local/Homebrew/Library/Homebrew/os/mac.rb:60:in `prerelease?'
3: from /usr/local/Homebrew/Library/Homebrew/os/mac.rb:28:in `version'
2: from /usr/local/Homebrew/Library/Homebrew/os/mac/version.rb:33:in `from_symbol'
1: from /usr/local/Homebrew/Library/Homebrew/os/mac/version.rb:33:in `fetch'
/usr/local/Homebrew/Library/Homebrew/os/mac/version.rb:33:in `block in from_symbol': unknown or unsupported macOS version: :dunno (MacOSVersionError)
阅读更多

Linux Screen命令汇编

常用的命令我就不啰嗦了:

  • -r 恢复连接
  • -d 断开连接
  • -S ? 新建屏幕 …

高阶玩儿法

重命名会话

发现自己之前-S起的名字太挫了,想重命名会话怎么搞?

阅读更多

Failed to clone nvm repo. Please report this!

Linux安装nvm报错,连接GitHub超时 …

root@VM-4-9-debian:~/nvm-0.39.7# ./install.sh
=> Downloading nvm from git to '/root/.nvm'
=> Cloning into '/root/.nvm'...
fatal: unable to access 'https://github.com/nvm-sh/nvm.git/': Failed to connect to github.com port 443 af
ter 129382 ms: Couldn't connect to server
Failed to clone nvm repo. Please report this!
阅读更多

腾讯云Ubuntu服务器安装图形化界面

登录腾讯云

➜  ~ ssh ubuntu@www.cctv3.net
The authenticity of host 'www.cctv3.net (110.42.253.75)' can't be established.
ED25519 key fingerprint is SHA256:1gTaZcgrHg5VDYmQSC+OwD7G/RNHv1HTuB/zYrOt2eM.
This host key is known by the following other names/addresses:
~/.ssh/known_hosts:7: 110.42.253.75
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
Warning: Permanently added 'www.cctv3.net' (ED25519) to the list of known hosts.
ubuntu@www.cctv3.net's password:
Welcome to Ubuntu 18.04.4 LTS (GNU/Linux 4.15.0-213-generic x86_64)

* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage

System information as of Mon Jan 22 19:38:33 CST 2024

System load: 0.0 Processes: 105
Usage of /: 4.3% of 98.31GB Users logged in: 0
Memory usage: 6% IP address for eth0: 10.0.4.9
Swap usage: 0%

* Strictly confined Kubernetes makes edge and IoT secure. Learn how MicroK8s
just raised the bar for easy, resilient and secure K8s cluster deployment.

https://ubuntu.com/engage/secure-kubernetes-at-the-edge

* Canonical Livepatch is available for installation.
- Reduce system reboots and improve kernel security. Activate at:
https://ubuntu.com/livepatch
New release '20.04.6 LTS' available.
Run 'do-release-upgrade' to upgrade to it.


Last login: Mon Jan 22 11:05:47 2024 from 58.60.186.1
To run a command as administrator (user "root"), use "sudo <command>".
See "man sudo_root" for details.
阅读更多

Unable to resolve module `./debugger-ui/debuggerWorker.d9da4ed7` from ``

公司的祖传代码升级,升级完了没法调试了 …

Error: Unable to resolve module `./debugger-ui/debuggerWorker.d9da4ed7` from ``:

None of these files exist:
* debugger-ui/debuggerWorker.d9da4ed7(.native|.native.js|.js|.native.json|.json|.native.ts|.ts|.native.tsx|.tsx)
* debugger-ui/debuggerWorker.d9da4ed7/index(.native|.native.js|.js|.native.json|.json|.native.ts|.ts|.native.tsx|.tsx)
at ModuleResolver.resolveDependency (/Users/sunyg/marineonline-mobile/node_modules/metro/src/node-haste/DependencyGraph/ModuleResolution.js:163:15)
at ResolutionRequest.resolveDependency (/Users/sunyg/marineonline-mobile/node_modules/metro/src/node-haste/DependencyGraph/ResolutionRequest.js:52:18)
at DependencyGraph.resolveDependency (/Users/sunyg/marineonline-mobile/node_modules/metro/src/node-haste/DependencyGraph.js:282:16)
at /Users/sunyg/marineonline-mobile/node_modules/metro/src/lib/transformHelpers.js:267:42
at /Users/sunyg/marineonline-mobile/node_modules/metro/src/Server.js:1305:37
at Generator.next (<anonymous>)
at asyncGeneratorStep (/Users/sunyg/marineonline-mobile/node_modules/metro/src/Server.js:99:24)
at _next (/Users/sunyg/marineonline-mobile/node_modules/metro/src/Server.js:119:9)
at runMicrotasks (<anonymous>)
at processTicksAndRejections (node:internal/process/task_queues:96:5)
::ffff:192.168.210.117 - - [18/Jan/2024:03:06:50 +0000] "POST /symbolicate HTTP/1.1" 500 - "-" "okhttp/4.8.1"
BUNDLE [android, dev] ./index.js ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓ 100.0% (1/1), done.

他奶奶的我就知道绝对是这个坑货搞的鬼 …

https://github.com/facebook/metro/issues/731

阅读更多

Failed to transform ?.jar/?.aar

> Task :app:desugarDevDebugFileDependencies FAILED
Execution failed for task ':app:desugarDevDebugFileDependencies'.
> Could not resolve all files for configuration ':app:devDebugRuntimeClasspath'.
> Failed to transform android-sdk-1.2.1.aar (com.paypal.checkout:android-sdk:1.2.1) to match attributes {artifactType=processed-jar, org.gradle.category=library, org.gradle.dependency.bundling=external, org.gradle.libraryelements=aar, org.gradle.status=release, org.gradle.usage=java-runtime}.
> Execution failed for JetifyTransform: /Users/sunyg/.gradle/caches/transforms-2/files-2.1/0c7dd15c0f53a65d39de0cadcd9b99fa/android-sdk-1.2.1/jars/classes.jar.
> Failed to transform '/Users/sunyg/.gradle/caches/transforms-2/files-2.1/0c7dd15c0f53a65d39de0cadcd9b99fa/android-sdk-1.2.1/jars/classes.jar' using Jetifier. Reason: null. (Run with --stacktrace for more details.)
> Failed to transform PayPalPartnerAuth-1.8.4.aar (com.paypal.android:PayPalPartnerAuth:1.8.4) to match attributes {artifactType=processed-jar, org.gradle.category=library, org.gradle.dependency.bundling=external, org.gradle.libraryelements=aar, org.gradle.status=release, org.gradle.usage=java-runtime}.
> Execution failed for JetifyTransform: /Users/sunyg/.gradle/caches/transforms-2/files-2.1/2af375fc36788e051fa39e778b7da182/PayPalPartnerAuth-1.8.4/jars/classes.jar.
> Failed to transform '/Users/sunyg/.gradle/caches/transforms-2/files-2.1/2af375fc36788e051fa39e778b7da182/PayPalPartnerAuth-1.8.4/jars/classes.jar' using Jetifier. Reason: null. (Run with --stacktrace for more details.)
> Failed to transform auth-sdk-thirdParty-1.4.0.aar (com.paypal.android.platform:auth-sdk-thirdParty:1.4.0) to match attributes {artifactType=processed-jar, org.gradle.category=library, org.gradle.dependency.bundling=external, org.gradle.libraryelements=aar, org.gradle.status=release, org.gradle.usage=java-runtime}.
> Execution failed for JetifyTransform: /Users/sunyg/.gradle/caches/transforms-2/files-2.1/fb630df5a6a959d0abfb5e0cef776121/auth-sdk-thirdParty-1.4.0/jars/classes.jar.
> Failed to transform '/Users/sunyg/.gradle/caches/transforms-2/files-2.1/fb630df5a6a959d0abfb5e0cef776121/auth-sdk-thirdParty-1.4.0/jars/classes.jar' using Jetifier. Reason: null. (Run with --stacktrace for more details.)

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
阅读更多

More than one file was found with OS independent path 'META-INF/com.android.tools/proguard/coroutines.pro'

* What went wrong:
Execution failed for task ':app:mergeDevDebugJavaResource'.
> A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$ActionFacade
> More than one file was found with OS independent path 'META-INF/com.android.tools/proguard/coroutines.pro'
阅读更多