Live data from Hacker News

Cleaning up my 200GB iCloud with some JavaScript

andykong.org

101–110 of 192 posts

Re: Cleaning up my 200GB iCloud with some JavaScript

#102
post #100
post #69

Earlier quoted context omitted.

>So as a consumer, do I just wave my hands and keep throwing more and more money at the problem, Yes. I can go and buy 1TB of Microsoft OneDrive or 2TB of Google Drive for less than a Franklin a year, and most people won't even need 1TB let alone 2TB. Both Microsoft and Google also offer 100GB plans for a Jackson a year, which is what I purchase myself. The average person can get by paying a Washington per month to A…

"640KB is more than anyone will ever need" It's a little absurd to think people don't need more than 2TB - especially on HN. Gamers will likely have 2TB in games alone, videographers often have many TBs of videos and photos from weddings and events in their life, many that care about health may have a few TB in genomic data mirrored on their computers to analyze, etc. I would imagine it's hard to find people that wou…

> Gamers will likely have 2TB in games alone

If I were to install all the games on my steam account it would be many hundreds of terabytes of total storage. In the end I have about a terabyte of games on my computer. And of that 0 bytes are in my cloud storage.

I've been an amateur photographer for over 15 years. I tend to curate the photos I keep, largely because I don't need 20+ pictures of the same scene. Its more of a burden to casually flip through my photos if the majority of them are near duplicates. In the end my total collection is only several hundred gigs.

Most people aren't videographers.

Most people in my family have far less than even 50 gigs of actual data they care about. They maybe take a dozen compressed photos a week, maybe 30 minutes of videos a month. A lot of my friends take even fewer photos and pictures.

Re: Cleaning up my 200GB iCloud with some JavaScript

#103

Surprisingly, I've received a similar storage notice from Apple before the holidays and I decided to download all photos/videos into my own media server instead of hosting it on iCloud. There is not an easy, straight-forward way to download your archive from iCloud. I am slowly getting there using multiple machines and devices. The issue with the recent changes with Apple is that they increase the prices for no good…

> There is not an easy, straight-forward way to download your archive from iCloud.

I use PhotoSync[0] to copy photos from my iPhone to a NAS. It's an excellent program.

It will even download photos from iCloud as needed and can do format conversions. I run it every few days to push new photos to my NAS so that I've always got a local copy (these also get backed up to Backblaze B2 nightly). The format conversion lets me keep HEIC+JPG pairs of my photos, so I have the original and something that's more readily usable.

What I really want is something that will do the same thing, but with iCloud Drive. I keep a bunch of stuff in there and it bothers me that I don't have a reasonable way to back it up. Apple's recommended methods[1] leave a lot to be desired.

[0] https://www.photosync-app.com/home

[1] https://support.apple.com/en-us/HT204055

Re: Cleaning up my 200GB iCloud with some JavaScript

#104
post #92

Photos.app doesn't show file size… so I thought, why not build a little Photos.app extension or a separate app that queries for large files? Turns out that the API doesn't expose "file size", at least I didn't find a straight-forward way. I think that all "photos" or "videos" are just a view of the underlying "photo or video object". If you crop a video, the full-size video will remain. Only if you export the video,…

this is the best plausible reason for why the file size differs. I've also noticed some unepxected media restoration (thought I cropped/edited a video, it is still there in full length and resolution). This also helps explain why my iPhone storage always seems to be at its limits, despite my obsessive management. Anyway, we all know foss unix ftw :P

> thought I cropped/edited a video, it is still there in full length and resolution

It's been possible to create a clip from a video file that merely changes what parts of the video are displayed without effecting the data in the original since the Classic Mac OS days.

If you want to completely remove unwanted portions of a video to reduce the size without a loss of quality, there are many options. LosslessCut is a cross platform option that is both free and open source.

https://github.com/mifi/lossless-cut

Re: Cleaning up my 200GB iCloud with some JavaScript

#105

I'm pretty sure that iCloud stores the full version and downloads a lower quality optimised version to your phone. If you open iPhone settings and browse to: > Apple ID > iCloud > Photos There is an option to 'Optimise iPhone Storage' which is enabled by default. This states: > If your phone is low on space, full resolution photos and videos are automatically replaced with smaller device sized versions. Full-Resoluti…

Downloads should still return the original file though, so that can't be used to explain the storage size discrepancy.

There are two kinds of download options on the iCloud website, the “full quality” (e.g. HEIC file for photos) or a “quick” / “small” download which is a JPG.

Re: Cleaning up my 200GB iCloud with some JavaScript

#106
some possible reasons to investigate:

1. older videos have a larger file size because they are encoded less efficiently (h264 vs h265)

2. gigabytes vs gibibytes (like how a 500GB drive formats to ~465 GiB)

3. rounding errors

4. Apple fucking its customers

5. combo of the above

Re: Cleaning up my 200GB iCloud with some JavaScript

#107
post #94
post #9

Earlier quoted context omitted.

The opaqueness is definitely a problem. My iMessage database has a corrupted spot somewhere in the message history; if I accidentally make the Messages app read that spot (via searching or scrolling back through old conversations) it'll silently start maxing out the CPU and burning energy for no reason. There is no error message, nothing obviously wrong-looking, and as far as I know everything works.

Hey, this sounds like an interesting problem. I am always looking for edge cases to test, if you have time would you mind checking if https://github.com/ReagentX/imessage-exporter works for you and if it crashes in that spot?

Holy crap. I've been looking for ways to archive my imessages somehow. imessage-exporter looks like exactly what I wanted. What a cool project!

Re: Cleaning up my 200GB iCloud with some JavaScript

#109
Tangent but does anyone else find iCloud sync random / slow?

The smart thing about having both an iPhone and a Macbook should potentially be; snap a bunch of photos, instantly have them available on the computer - but no. Apple apparently chooses a random time depending on 100 factors to upload the photos in the next 30 minutes to 7 days.

So you often have to airdrop a bunch of photos files completely invalidating the purpose of the sync function.

Re: Cleaning up my 200GB iCloud with some JavaScript

#110
post #94

Earlier quoted context omitted.

Hey, this sounds like an interesting problem. I am always looking for edge cases to test, if you have time would you mind checking if https://github.com/ReagentX/imessage-exporter works for you and if it crashes in that spot?

Holy crap. I've been looking for ways to archive my imessages somehow. imessage-exporter looks like exactly what I wanted. What a cool project!

Cheers! It was fun to build.
Post reply on HN