How to Open a Mac App Package (And Why You'd Want To)
More often than not, Mac applications come in a neat little package, instead of a mess of folders. If you want to uninstall an app, simply delete the package and most of the time it's all gone.
More often than not, Mac applications come in a neat little package, instead of a mess of folders. If you want to uninstall an app, simply delete the package and most of the time it's all gone.
It's official. Apple has just announced the date for this year's WWDC (Worldwide Developer Conference), kicking off the event with a big keynote on June 9th. The event will run through June 13th at Apple Park.
If you run any type of home server, then you've likely needed to access it when away from home. I know I have. That's where running a VPN at home comes in, and here's how I do just that.
Believe it or not, some gamers prefer Macs to PCs for gaming. Thanks to Apple’s M-series chips and various software enhancements, macOS has significantly improved its gaming capabilities, making it an increasingly viable option.
在调试程序时,有时候我们希望一直运行程序直到遇到错误。GDB(GNU 调试器)和 LLDB(LLVM 调试器)都提供了自动化此过程的方法。
这在调试一些不稳定的程序非常有用,例如有时候写的一些单元测试可能随机崩溃SegFault。最近我在调试一个测试每跑1000次就有一次崩溃的时候就发现gdb/lldb调试器非常有用。
GDB(GNU 调试器)和 LLDB(LLVM 调试器)是用于低级别应用程序调试的强大工具。GDB 传统上用于由 GCC 编译的程序,而 LLDB 是 LLVM 项目的一部分,与 Clang 无缝配合。两者都提供强大的功能,但 GDB 在 Linux 环境中更常见,而 LLDB 在 macOS 上以及处理 Swift 时更受青睐。
调试重复性任务可能很乏味。通过自动化这些任务,直到发生错误,可以节省大量时间和精力。以下是如何在 GDB 和 LLDB 中设置重复执行直到遇到错误的步骤。
下面是一个 GDB 脚本,它会重复执行,直到发生错误:
while 1 run if $_exitcode != 0 echo "发生错误,退出码:$_exitcode\n" break end end
要运行此脚本,将其保存为 repeat_until_error.gdb
,然后使用以下命令执行 GDB:
gdb -q -x repeat_until_error.gdb ./your_program
或者,当你处于 gdb 提示符时,运行:
source repeat_until_error.gdb
“run” 命令用于启动程序,你可以为它添加参数,例如:
run param1 param2 ...
你也可以使用 “r” 作为 “run” 的简写。
类似地,在 LLDB 中,你可以使用以下脚本实现相同的效果:
while (1) run process launch if (process status != 0) script print("发生错误,退出码:", lldb.process.GetExitStatus()) break end end
要运行此脚本,将其保存为 repeat_until_error.lldb
,然后运行:
lldb --source repeat_until_error.lldb ./your_program
或者,在 lldb 提示符处运行:
source repeat_until_error.lldb
在 “run” 命令之后,你还可以通过附加参数来启动程序,例如:
run param1 param2
GDB 和 LLDB 都提供了方便的方法来自动化调试任务,选择使用哪种工具通常取决于你所使用的平台和工具链。GDB 与 GCC 的集成使其成为 Linux 开发者的首选,而 LLDB 在与 Clang 和 macOS 的无缝配合方面同样强大。
自动化重复的调试命令可以为你节省大量时间和精力 —— 无论你使用 GDB 还是 LLDB,这些脚本都能帮助你简化工作流程。
英文:How to Repeat Until Errors using GDB or LLDB Debugger?
本文一共 603 个汉字, 你数一下对不对.The idea of using a MacBook as a desktop Mac sounds great, but there are some problems. Nobody wants to mess with a rat's nest of cables when changing scenery, and what about performance? Thankfully, with modern equipment, it’s not that difficult anymore.
There's no shortage of third-party editing apps for editing photos on your Mac. However, the built-in Photos app on macOS is a capable photo editor that probably satisfies the needs of most people.
Macs used to have no end of gaming options, until about the turn of the century. Since then, gaming on a Mac has been a bit of a joke at Apple's expense. However, in recent years, things have taken a turn for the better, with Apple making many moves that should result in more games coming to its platform,
2025 is the year I was determined to keep a journal. And, instead of having to spend money monthly on an app like Day One, I decided to give Obsidian a try. There's no going back.
New iPhones updates are automatically enabling AI-powered Apple Intelligence functionality, even for people who already switched it off. It’s not clear if this is a bug or intended behavior, but either way, it’s getting to be annoying.
Your Mac is better for gaming than you give it credit for, and it’s only getting better with each new macOS release. Here are some features you might have missed.
Rumors suggest that Apple will announce a major iOS, iPadOS, and macOS software design overhaul at WWDC 2025. If true, this will be the biggest iOS UI revamp since 2013, and it will replace a lot of the iPhone-like design elements that invaded macOS in 2020.
本刊物不定期发布,推荐通过 RSS 订阅:https://anotherdayu.com/feed/
Vercel 和 Netlify 的替代品,更简单的部署 Docker 应用。
|
很多机构,特别是政府机构,不接受数字签名,而签名扫描的打印件可以。这个开源工具可以让 PDF 文件看起来像打印、签名然后重新扫描过一样。
|
Shift-Z 这个启动键确实挺不错的,用了几天很舒服。
|
可以从小红书上下载无水印的作品文件。
|
这是一个跑步教练软件,帮助用户培养运动习惯,直到能一次性不中断跑5km。
一般会计划每周跑3-4次,散步+跑步交替,一点点加量。2-3个月之后帮助训练者恢复成能单次跑5km的程度。之后还有10km的扩充计划,循序渐进,挺好的。。
| 「Does spatial distribution heterogeneity exist in video games: Evidence from Genshin Impact’s map」
这篇研究论文通过对《原神》游戏地图的空间分布异质性进行定量分析,探讨了虚拟世界中的空间特征。结果表明,虚拟游戏世界确实存在空间分布异质性,但其模式比现实世界更加简单和规整。
关联:PIVOT Vol.9 组会分享什么?一些有趣的科研论文
|
发现了一个公共卫生领域的播客也叫 PIVOT,缘分啊。
|
医学教育学相关研究,探讨性别差异在心理健康与学业表现之间的关系。女大学生心理健康状况不良与学业成绩较差显著相关,SCL-90量表六个维度与学业成绩之间存在剂量依赖关系。相比之下,男性学生中未观察到类似结果。这表明性别在心理健康与学业表现的关系中起着重要作用,需进一步挖掘多维度心理健康对学生学业的影响。
|
macOS 原生应用程序,利用AI技术进行图像超分辨率处理。
|
基于随机事件的文本类游戏引擎,模拟PhD学生的生活经历。
|
「Wittgenstein and Word2vec: Capturing Relational Meaning in Language and Thought」
这篇文章探讨了语言意义的本质,通过比较维特根斯坦的语言游戏理论、Word2vec 自然语言处理模型和细胞生物学中的概念映射,展示了概念间关系性意义的重要性。作者认为,通过在多维空间中测量概念之间的”距离”,我们可以更好地理解和表达意义,这种方法不仅适用于语言,还可能反映了人类思考的基本方式。
本刊物不定期发布,推荐通过 RSS 订阅:https://anotherdayu.com/feed/
推荐几个最近用着很舒服的 macOS 软件!
Mailmate,朋友推荐的一款 macOS IMAP 电子邮件客户端,日常价格为每 3 个月 10 美元,前几天可以 1 美元购买 3 个月的使用权限(已过期),就试了试,结果非常惊喜。付费期限结束后,会自动转为免费版,似乎也够日常使用(还未测试)。很踏实的设计风格,比 Apple mail 和 Spark 细节好很多。如下图,如果邮件中提到了 attachment,但没有添加附件,还会提醒。
Kinopio,一款画板软件,风格比较独特,可以分享页面,并嵌入网页,示例:第一次中距离徒步 Yr Wyddfa。从 Obsidian 转出后,偶有画板需求,但不想再额外使用一个笔记软件,就会用 Excalidraw,但 Excalidraw 稍有些粗糙。Kinopio 则刚刚好,网页版轻量化,还能导出为 Obsidian 的 JSON Canvas file format 格式和 PDF,易于储存和索引。
new file menu,为 macOS 右键菜单增加新建文件的功能。类似的软件有很多,但部分在系统更新后失效,这款则比较稳定简单。
Trickster,快速索引近期访问的文件,优点是能索引 Devonthink 等软件内部的文件。
codepiper,自动复制 macOS 中的短信验证码,很易用。
Rapidmg,macOS 安装 DMG 文件时的拖拽流程比较累赘,这个软件则省去了该步骤。
FluentRead,Firefox插件,类似于沉浸式翻译,优点是开源,设置界面简洁舒适。缺点是目前没有一键全网页翻译,只有段落翻译快捷键。
TL;DR: The Developers in charge of Steam Cloud Save File Sync for 100% Orange Juice don’t know how to handle it. They may mess up your save files, and you may be unaware of it until the loss is done.
Notice: This advice may become obsolete in the future.
Notice 2: English isn’t my native tongue.
Developers are stubborn.
I will use 100oj as 100% Orange Juice for short.
100oj is a beloved game. I declare it as the best online board game ever, with no hesitation.
The very original 100oj is surely made for Windows.
The earliest Steam page capture from web.archive.original
Meanwhile, Valve is making Steam OS, and then, Steam Deck. Proton made Playing Windows Games on Linux become a real thing. (Nah, I don’t want to talk about wine. No one would really want to use those for real generic gaming).
So basically, Proton is a fork of Wine, and this software can run Windows games on Linux, and players don’t need to worry about most of the How to run Windows games on Linux things.
It is also very convenient for most game Developers. Proton just works. No need to change anything, unless you use some very unrecommended/unofficial/deprecated/obsoleted Windows API, which may happen in very old days.
100oj v3.3 on Linux Mint.
Sora on Linux Mint.
Funny thing is, the OP animation is in WMV format (Windows Media Video), which was made by Microsoft and was not kind of an open/free format. So if you play Sora on Linux with Proton, the game will crash if you stay at the start screen long enough, and try to wait for the OP animation to play.
Funnier thing is, the OP animation WMV file is actually
All of them are open and royalty-free.
Well, let’s not talk about Sora right now.
I don’t remember when it was exactly.
The wiki says it was Sep 20th, 2024, v3.23 Versioned Hotfix 1, but the official Discord announcement is Oct 6th, 2024.
100oj now officially has a Linux native build.
This is where/when/how a nightmare begins.
Here it is. You can read the paragraph heading, and if you know Linux, you already know what I am talking about.
On Oct 7th, 2024, while I was checking on the Linux side, I found my save file on the Linux side is kinda outdated compared to the save on the Windows side, despite Steam already saying Cloud Status is Up to date. Also, the Free Weekly Character is different from the Windows side.
Turned out there were two directories.
I posted this on the official Discord Support Channel.
After that, a developer from 100oj Official replied:
So basically, the old Steam-Play, aka the Proton one worked fine, but when the Linux native build came out, they messed up the path because of case-sensitive.
That’s kinda acceptable for a developer who doesn’t have much experience on Linux.
Well, the easiest way to fix my problem is, because I play 100oj on Windows most, I just wanted to keep the Windows savefile, so just delete both Save and save on my Linux side, and let Steam re-sync from the steam-cloud. That worked well.
I thought this case-sensitive crisis was over.
Well the most recent major update of 100oj is 3.24, released on Nov 24th, 2024.
Talking from my point of view, it was a terribly stupid idea to accomplish all these at one time.
I mean, what are they? Fresh inexperienced just-graduated noob programmers? What are they thinking?
100oj game crashed, a lot, after that release. The Discord support channel became a total mess.
Look at the Version 3.24 release note on orangejuice.wiki. There are one versioned hotfix and 4 unversioned hotfixes, lasting for 16 days. You should know it was a mess.
I mean, look at this one:
This was reported by me, and what’s the first reply I received?
“You are not doing that right that’s your fault lmao bronze you noob gamer trash.”
Well funny thing: the 100oj start-entry is a shell script. It looked like this:
To no programmers, I will explain it: The script wants to load a file, and it should be at ‘/home/rapha/.steam/debian-installation/ubuntu12_64/gameoverlayrenderer.so’. The path is formed with:
There are two problems.
The first one: Who is rapha? It’s not me, obviously.
The second one: in the Steam installation directory ‘/.steam’, the file ‘ameoverlayrenderer.so’ is actually located at ‘/ubuntu12_64/gameoverlayrenderer.so’, thus there is no such a prefix ‘/debian-installation/’.
After some tests, I figured out there were some useful variables when starting something from steam client.
https://www.bilibili.com/video/BV1R6BRYmEoD/
Both STEAM_BASE_FOLDER and STEAM_COMPAT_CLIENT_INSTALL_PATH are reliable. I also searched on Google but didn’t find any official valve/steam document about how to locate where the steam client is installed.
I recommended “$HOME/.local/share/Steam/ubuntu12_64/gameoverlayrenderer.so” and “${STEAM_COMPAT_CLIENT_INSTALL_PATH}/ubuntu12_64/gameoverlayrenderer.so”, but got refused.
Well of course he didn’t know what a symbolic link is.
During the discussion, a new unversioned hotfix was released:
Fixing by this:
So they removed the ‘/home/rapha/’ part but still kept the ‘/debian-installation/’ there. I don’t know why.
I asked. No response.
Thankfully, some Linux users are aware of that and they know how to search and read.
Turns out there is no need to load the steam overly library manually when start from Steam.
Well, at least I helped someone.
Note: Right now they have fixed it stealthily, with no release notes. The entry script is just like this:
Well. No credit to me.
Now they supported MacOS.
New platform, new steam cloud sync issues.
They even made a post on How to deal with save problems.
But there isn’t any of the cross-platform savefile case-sensitivity issue information. I had to ask for adding that part.
I think it’s about Unversioned Hotfix 4 when they tried to fix the macOS saves sync issue.
After that update, my Linux 100oj couldn’t sync saves anymore.
I tried the old way, removing all save files on Linux, expecting that steam client could just download the saves from steam cloud.
Nope, that was not happening.
After a lot of trying and testing, I figured out what is happening.
On Linux, 100oj is using both Save and save at the same time. When there are no save files:
And here is the official response.
See, that’s why I didn’t even bother explaining it.
And you thought at least they managed to make macOS work? Too bad. Look at this screenshot of a macOS user’s Steam Cloud Storage, and see what a mess they had made.
Well for now, they could still change anything stealthily with no release note. May become better, or become worse. I don’t know.
I even talked about this to the guy who was taking charge of 100oj Chinese localization.
Developers are stubborn.
Well I don’t want to care about it anymore. I get no paid nor credit.
100oj Official admitted they messed up the steam cloud setting for savefile sync.
They also said they fixed it.
I’m not buying it. Anyway, there is no credit to me.
DEVONtechnologies 是一个 macOS 软件公司,其最知名的产品 Devonthink,用于文件和信息管理。
每次逛 Devonthink 的社区 —— DEVONtechnologies Community,都能给我不小的惊喜。前段时间发现 DEVONtechnologies 原来还发布了很多功能强大的免费软件/插件:
WordService,针对选择文本的小工具,比如转成繁体中文、格式化文本等。
CalcService,是一款公式计算插件,在文本界面都可以使用。
EasyFind,用于替代 Spotlight 的文件检索软件,适合更高级的精确文件搜索需求。相似的软件还有 GoToFile 和 FoxTrot Search。
Neo Network Utility,网络工具,用于获取网络适配器信息并诊断常见的网络问题。
PhotoStickies,将喜欢的图片直接展示在桌面上。桌面相册(photoalbum)也有相似地功能,样式稍微好看一些。
ThumbsUp,设置好参数后,将图像拖拽到该软件的图标上,即可调整图片分辨率和大小。
XMenu,在菜单栏添加程序、文件、文档、文本的快速访问窗口。
DEVONagent Lite,网页检索工具,可以提前配置一些搜索习惯。完整付费版为:DEVONagent Express 和 DEVONagent Pro。
检索的时候,在关键词后加 “Reddit”,总能搜到一些有趣的讨论帖。
过去知乎、小红书也能起到这个功能,但随着它们商业化价值变高,越来越多功利性比较强的信息进入,如广告和 AI 生成的文字,内容的真实性变的越来越难判断。
论坛和社区的流量相对较小,其中的信息还显得有些人味,也往往更深入。
成也流量,败也流量,不知道小红书还能坚持多久。
Reddit 之外,其实还有很多偏好性强的小论坛,以下是我偶尔会逛逛的:
如想发掘更多论坛,可以试试这两个渠道:ListOfSubreddits 和 Discourse Discover。
主动寻找,才能找到更符合自己兴趣和性格的内容。
如果你使用的是 macOS Ventura(MacOS 13),系统已默认支持 AVIF 格式打开和预览。对于更旧的系统版本,需要通过安装第三方图片浏览软件或拖到浏览器中查看。
AVIF QuickLook 插件可以通过4个简单的步骤,实现在系统直接预览 AVIF 格式,该插件由国内一个作者 DreamPiggy 开发。
要求:
1、macOS 10.11+ (Big Sur+) 以上版本
2、M1/Intel Mac 都支持
步骤:
1、在 Github Release Page 下载最新的 AVIFQuickLook.qlgenerator
;
2、打开 访达.app (Finder);
3、通过快捷键 Shift + Command + G
打开“前往文件夹”窗口,输入 ~/Library/QuickLook/
然后回车。 macOS Catalina 以上版本, 使用 /Library/QuickLook/
;
4、把下载的 AVIFQuickLook.qlgenerator
复制到该文件夹内,可能需要输入电脑密码确认。
如果你已经安装了 Homebrew,只需要一行命令即可。
brew install avifquicklook
安装完,系统就支持直接预览 AVIF 格式了。
继上一文介绍了我“利用 Mac 快速操作实现图片批量转换为 WebP 格式”捣腾成功后,希望通过同样的方法实现利用 Mac 快速操作实现图片批量转换为 AVIF 格式,捣腾结果分享如下。
AVIF 是一种基于AV1 视频格式的现代图片格式,实现卓越的压缩效率,同时保持高图像质量。AVIF 通常比WebP、JPEG、PNG 和 GIF 具有更好的压缩效果,并且旨在取代它们。AVIF 对宽色域、高动态范围 (HDR) 和渐进式渲染的支持增强了视觉体验,预示着图像细节精美且高效交付的未来。号称 Web 开发人员和摄影师的首选。据统计,AVIF 全球使用情况为 92.95%,除 IE 浏览器、Opera Mini、QQ 浏览器、KaiOS 浏览器外都已支持,WordPress 6.5+ 已支持 AVIF 格式。
通过 AVIF 格式其开发组织“开放媒体联盟”(AOMedia),顺藤摸瓜在其 Github 账号上找到了 libavif 这个用于编码和解码 AVIF 格式的库和使用文档。
我的操作步骤如下:
这部分就不重复介绍了,见“利用 Mac 快速操作实现图片批量转换为 WebP 格式”一文。
在终端中运行一下命令:
brew install libavif
回车直至安装完成。注意是否有出错或文件无授权的提示,按需对文件夹进行可操作授权。注意 libavif 包的安装路径,后面需要用到。
2、在工作流的顶部,它显示“工作流程收到当前”,选择“图像文件”,然后在“位于”下选择“访达.app”;
3、接下来,在“自动操作”的左侧面板,在“资源库”下选择“实用工具”,然后将“运行 Shell 脚本”,拖放到右侧工作流程面板中;
4、对于“运行 Shell 脚本”,“Shell”选择“/bin/zsh”,“传递输入”选择“作为自变量”。
把以下代码片段粘贴到下面文本框中:
for f in "$@" do fname="${f%.*}.avif" /usr/local/Cellar/libavif/1.1.1/bin/avifenc -s 10 -q 85 "$f" "${f%.*}.avif" done
然后在“文件”菜单选择“储存”,保存文件名为“转换为 AVIF”,保存到默认地址即可。
注意:
1)libavif 的路径是为通过 Homebrew 安装的 libavif 设置的,如果您手动安装了 libavif,那么它可能在 /usr/bin 中,您需要相应地调整路径(我的最终路径是 /usr/local/Cellar/libavif/1.1.1/bin/avifenc );
2)-q 质量标志当前设置为 85,默认为 60,但您可以将其设置为 1-100 之间的任何值(越高将产生更高质量的图像,但压缩较少);-s 代表速度,默认为6;默认不删除照片 exif 信息,需删除则加上 --ignore-exif 参数。
5、选择你需要转换格式的图片,可多选,右键菜单的“快速操作”中选择“转换为 AVIF”选项,图片将在当前文件夹中自动生成 AVIF 格式文件。
至此,教程结束。
下图为 WebP 和 AVIF 格式压缩率都设置为 85 所得到的压缩结果,结果是 WebP 的文件更小一些,有点困惑。不知道是不是我设置的压缩率太高了,libavif 官方默认值是 60。本文方法大致如上,至于多少压缩率更好,大家自己摸索吧。
另外,我通过 AVIFQuickLook 插件,已经实现了在老苹果中直接预览 AVIF 格式。使用 Brew 进行安装,命令如下:
brew install avifquicklook
如有误,或有更好的方案,欢迎指正和交流。