tinyapps.org / blog


Twitter - Disable auto links in tweets #

Having set up IFTTT to autopost blog updates on a recovered Twitter handle, I did my best to forget all about it.

However, I recently discovered that Twitter automatically inserts hyperlinks for text that matches certain patterns (e.g., "Mail.app" becomes a link to said domain), prompting me to go back and delete such tweets, namely:

I was able to delete today's earlier tweet (Mojave - Where did DVD Player.app go?) and repost it with the hyperlink disabled (why can tweets not be edited?) by inserting a zero width space after the dot as explained by Amit Agarwal.

See also:

/misc | Oct 23, 2018

Backing up a large Gmail / G Suite account #

is theoretically possible via Google Takeout, but there are issues:

Got Your Back (GYB) does not suffer from these issues; messages are downloaded as individual EML files, sorted into folders by year, month, and day:

$ gyb --email name@example.com --action estimate

Select the actions you wish GYB to be able to perform for name@example.com

[ ]  0)  Gmail Backup And Restore - read/write mailbox access
[ ]  1)  Gmail Backup Only - read-only mailbox access
[ ]  2)  Gmail Restore Only - write-only mailbox access and label management
[*]  3)  Gmail Full Access - read/write mailbox access and message purge
[ ]  4)  No Gmail Access

[ ]  5)  Groups Restore - write to G Suite Groups Archive
[*]  6)  Storage Quota - Drive app config scope used for --action quota

      7)  Continue
7

Your browser has been opened to visit:

    https://accounts.google.com/o/oauth2/auth...

If your browser is on a different machine then press CTRL+C and
create a file called nobrowser.txt in the same folder as GYB.

Authentication successful.
Got 67100 Message IDs                                                           
GYB needs to examine 67100 messages
GYB already has a backup of 0 messages
GYB needs to estimate 67100 messages
Estimated size 26.47gb 67100/67100 messages 

$ gyb --email name@example.com --action backup

Using backup folder GYB-GMail-Backup-name@example.com
Got 67100 Message IDs                                                           
GYB needs to examine 67100 messages
GYB already has a backup of 0 messages
GYB needs to backup 67100 messages
backed up 67100 of 67100 messages                                               

GYB needs to refresh 0 messages

If desired, import the collection into Thunderbird via ImportExportTools.

If you need to copy the massive collection of EML files, tar it without compression to save a LOT of time (pv is of course optional, but very handy when tarring tens of thousands of files):

$ tar -c ./GYB-GMail-Backup-user\@example.com/ | pv -s $(gdu -sb ./GYB-GMail-Backup-user\@example.com/ | awk '{print $1}') > user\@example.com.tar
4.03GiB 0:00:23 [ 177MiB/s] [====>                             ] 15% ETA 0:02:08

* Attempting to split a ~26GB MBOX file by label via mbox_split.py or WB Optimum's script on which it is based did not avail.

UPDATE: Royce Williams kindly informs us of outtake, which "sync[s] Gmail to maildir...quickly", "uses the Gmail API to efficiently sync only deltas", and "can also be limited to a specific label". Crafted in Go by Google software engineer, Daniel Margolis. (On a related note, Evolution is swell for browsing and searching Maildir directories; add via Edit > Preferences > Mail Accounts > Add > Next > enter required info and deselect "Look up mail server details based on the entered e-mail address" > Next > for "Server Type:" select "Maildir-format mail directories" > select the "Mail Directory:" location, etc.)

/misc | Sep 25, 2018

Unexpected SCSI Command Failure: 00h - No SCSI controller error #

In an Adaptec SCSI Card 29320LPE's Adaptec SCSISelect Utility, neither "Format Disk" nor "Verify Disk Media" would work for two Fujitsu Ultra-320 SCSI 146GB (MAW3147NC) hard drives, immediately returning "Unexpected SCSI Command Failure" and "00h - No SCSI controller error". Both functions worked normally on two Seagate Ultra-320 SCSI 73.4GB (ST373405LC) drives.

When a Verify or Low Level Format is attempted on the hard drive, it responds with some error codes did not sound very promising:

If the error occurs in both Format and Verify, it usually indicates a defective drive. Contact the drive vendor for interpretation of other errors.

Happily, Unexpected SCSI command failure message when attempting low level format held the answer:

One reason for this could be the way the SCSI controller is set up to hand-shake with the device. This can be changed through the SCSISelect utility. Enter the SCSI Select utility by pressing CTRL-A on system boot or insert the SCSI Select diskette.

In the SCSI Select utility, take the option for Configure/View Host Adapter Settings. Then choose SCSI Device Configuration.

On the next screen you will see the SCSI ID's listed across the top and the options to set for each ID listed down the left side. For the SCSI ID of the hard drive that you are trying to verify or format, set Initiate Sync Negotiation to NO ( on U160/U320 controllers change Initiate Wide Negotiation = No), Enable Disconnection to NO, and Maximum Sync Transfer Rate to 5mb/sec. Exit the utility, saving the changes.

While "Verify Disk Media" failed if run first, running "Format Disk" then "Verify Disk Media" worked. Increasing the "Maximum Sync Transfer Rate" to 40MB/sec had no ill-effect and made verifying the format via hexdump much faster.

/misc | Sep 13, 2018

# On reputation #

Live never to be ashamed if anything you do or say is published around the world -- even if what is published is not true.

Illusions: The Adventures of a Reluctant Messiah by Richard Bach

A certain devotee asked Maharshi about some disagreeable statements made by a certain man well-known to Maharshi. He said, "I permit him to do so. I have permitted him already. Let him do so even more. Let others follow suit. Only let them leave me alone. If because of these reports no one comes to me, I shall consider it a great service done to me.

Talks with Sri Ramana Maharshi recorded by Munagala Venkataramiah

He who with equanimity surveys
Lustre of goodness, strife of passion, sloth
Of ignorance, not angry if they are,
Not angry when they are not: he who sits
A sojourner and stranger in their midst
Unruffled, standing off, saying--serene--
When troubles break, "These be the Qualities!"
He unto whom--self-centred--grief and joy
Sound as one word; to whose deep-seeing eyes
The clod, the marble, and the gold are one;
Whose equal heart holds the same gentleness
For lovely and unlovely things, firm-set,
Well-pleased in praise and dispraise; satisfied
With honour or dishonour; unto friends
And unto foes alike in tolerance;
Detached from undertakings,--he is named
Surmounter of the Qualities!

The Song Celestial, Or, Bhagavad-gîtâ translated by Edwin Arnold

/misc | Aug 03, 2018

Autoreply to SMS, MMS, and iMessage text messages without jailbreaking or driving #

by leveraging iOS 11's Do Not Disturb while driving feature:
  1. Settings > Do Not Disturb
  2. enable Do Not Disturb > DO NOT DISTURB WHILE DRIVING > Activate > Manually > back > Auto-Reply > enter desired mesage
  3. Settings > Control Center > Customize Controls > tap plus symbol next to Do Not Disturb While Driving
  4. swipe up to reveal Control Center > tap automobile icon to enable autoreplies

Notes:

/misc | Jul 05, 2018

Add SRT subtitles to DVD / VIDEO_TS without re-encoding #

Steps

  1. Rip DVD to VIDEO_TS

  2. Losslessly convert and merge desired VOBs in VIDEO_TS to a single MPG1 via VOB2MPG or ffmpeg, e.g.,
    ffmpeg -i 'concat:VTS_01_1.VOB|VTS_01_2.VOB|VTS_01_3.VOB' -acodec copy -vcodec copy combined.mpg

  3. Run DVDStyler and select new project options (e.g., DVD-9 (8.5GB), NTSC 720x480, AC3, etc) > OK > No template

  4. File browser > drag MPG created in step 1 to the Titleset Manager at the bottom of the program window

  5. Right click "Menu 1" in the Titleset Manager > Delete > Yes

  6. Right click "Title 1" in the Titleset Manager > Properties...

    1. Verify that video and audio are set to "Copy" and that "do not remultiplex/transcode" is checked

    2. Delete "call last menu;" from "Post commands:"2

    3. Click the green plus symbol > select your SRT file3 > Open

    4. Click the ... button next to "Subtitle: srt"

    5. Select desired font face/size (the default 28pt Arial worked best, but there are many fans of PT Sans Narrow Bold) and fill color (light gray was more pleasing than the default yellow) > OK > OK

  7. File > Burn DVD... > select "just generate" to create new VIDEO_TS with subtitles > Start

Footnotes

  1. Merely concatenating VOBs via VOBMerge or cat *.vob > merged.vob resulted in problems with the playback timeline and location. See VOB files reporting wrong playing time and DVDVob2Mpg's homepage. The latter states in part, "VOB and VRO files contain the MPEG, but also various other data, and headers may be incomplete or wrong etc. Because of that, VOB and VRO files typically don't play well using media players ... Typical problems are: timing issues, not being able to show the progress properly, no way to skip forward, crashes, missing audio, audio off sync, only showing the first 5 seconds of the video etc."

  2. To resolve "Cannot jump to menu" error.

  3. Had to resave SRT in Notepad with UTF-8 encoding to resolve "Error 42 -- Illegal byte sequence -- decoding subtitle file at approx line..."

Alternate methods utilizing SubtitleCreator

/misc | Jun 28, 2018

NoFan CS-80 drive brackets are NOT screwless #

Purchased a NoFan CS-80 PC case after reading that it "offers 9 EZ-SWAP drive bays and screwless installation" and is "conveniently designed so that a drive can be easily attached or detached from a bay without any extra tool":

NoFan CS-80 drive bay trays are NOT screwless

Should have glanced at the manual first, which shows 2.5" and 3.5" drives being screwed into the caddy:

Is this what you would call screwless?

Was expecting something actually tool-less, like this Corsair hard drive tray, which is at least screwless for 3.5" drives (2.5" drives mount to the bottom with screws):

Corsair CC-8930040 hard drive tray

Even better would be something completely tray-less, like the Corsair Carbide 200R's drive cage (though its plastic tabs should really be metal):

Corsair Carbide 200R tool free drive cage

/misc | Jun 17, 2018

Can Data from a Zero-Filled Hard Drive be Recovered? #

posted to the docs section.

/misc | Jun 04, 2018

Excerpts from Michel Peissel's Zanskar: The Hidden Kingdom #

Shangri-La?

I stepped outside and again I was struck by the magnificent view: a full circle of peaks surrounded the flat sea of the central plain dotted with its villages, refuges in a world unfit for man. If ever there lay a valley cut off from the world, a hidden, secret land, it was Zanskar. I could hardly believe that only recently I had left a world which is polluted and over-populated. Everything in Zanskar I found near to perfection: nothing, so it seemed, was out of place or unnatural. ... There was nothing here to tarnish the harmony of nature in which man has his natural place blending with the earth...

Fleas in Heaven

Finally I retired to a nocturnal safari against the terrible fleas. Someone, alas, had forgotten to explain to them the deadly effects of DDT, for they completely ignored the floods of insecticide with which I had covered my body. Leeches in the lower, damp southern Himalayas and fleas in the north are responsible for the real hardships of Himalayan travel. My parasites and I awoke early the next day.

At last I lay down to what I thought was well-earned sleep only to appreciate I had overlooked the fleas for which Kargil is famous. As I sat scratching myself I thought of all those travellers who had passed sleepless nights at this ancient crossroads of caravans heading for Tibet, Afghanistan, China and Sinkiang.

I must admit I needed self-control not to kill the fleas I caught in the chapel. Instead, with traditional respect for life, I placed the offenders on the ground without squashing them, thus leaving them free to start a new career on someone else.

For the night I was offered a small room in a large house that seemed neat and reasonably clean. Little could I then foresee that this was to result in severe wounds, much frustration and eight full days of furious scratching. 'To bite a flea is hardly food for the stomach but how nourishing for the soul,' goes a Tibetan proverb. I had to agree as, forgetting all taboos about respecting life, and in spite of the difference in size and the Geneva convention, I killed all prisoners!

Belief

Usually it takes me a week to get rid of the habits of my rational Western self, to stop querying every fact and figure and searching for an explanation to every phenomenon. This period over, I began to believe in witches and ghosts, gods and demons, good and evil spirits and endless other characters that in the West I liked to consider imaginary—in the same manner that Lobsang would consider unreal and laugh at all the dreary statistics in which we believe, such as the height in feet of our tallest buildings, or the exact distance in miles between the earth and the moon, the facts and figures which mould our lives and command respect in our figure-mad world. But what do figures mean, or spirits, if one docs not believe in them? The answer is nothing, for it is Faith that counts. Often we would be at a loss to check many of the facts we believe in; we accept them with that same blind faith with which I now accepted the presence of demons and the miracle of the [imprint in rock of a] footprint [said to be Padma Sambhava's].

/misc | Apr 19, 2018

A scattering of dried figs and nuts #

Free from hindrance are those things which lie in the sphere of the moral purpose, and subject to hindrance are those which lie outside the sphere of the moral purpose. And so, if he regards his own good and advantage as residing in these things alone, in those, namely, which are free from hindrance and under his control, he will be free, serene, happy, unharmed, high-minded, reverent, giving thanks for all things to God, under no circumstances finding fault with anything that has happened, nor blaming anything; if, however, he regards his good and advantage as residing in externals and things outside the sphere of his moral purpose, he must needs be hindered and restrained, be a slave to those who have control over these things which he has admired and fears; he must needs be irreverent, forasmuch as he thinks that God is injuring him, and be unfair, always trying to secure for himself more than his share, and must needs be of an abject and mean spirit.

When a man has once grasped all this, what is there to prevent him from living with a light heart and an obedient disposition; with a gentle spirit awaiting anything that may yet befall, and enduring that which has already befallen? "Would you have me bear poverty?" Bring it on and you shall see what poverty is when it finds a good actor to play the part. "Would you have me hold office?" Bring it on. "Would you have me suffer deprivation of office?" Bring it on. "Well, and would you have me bear troubles?" Bring them on too. "Well, and exile?" Wherever I go it will be well with me, for here where I am it was well with me, not because of my location, but because of my judgements, and these I shall carry away with me; nor, indeed, can any man take these away from me, but they are the only things that are mine, and they cannot be taken away, and with the possession of them I am content, wherever I be and whatever I do. "But it is now time to die." Why say "die"? Make no tragic parade of the matter, but speak of it as it is: "It is now tune for the material of which you are constituted to be restored to those elements from which it came." And what is there terrible about that? What one of the things that make up the universe will be lost, what novel or unreasonable thing will have taken place? Is it for this that the tyrant inspires fear? Is it because of this that his guards seem to have long and sharp swords? Let others see to that; I have considered all this, no one has authority over me. I have been set free by God, I know His commands, no one has power any longer to make a slave of me, I have the right kind of emancipator, and the right kind of judges. "Am I not master of your body?" Very well, what is that to me? "Am I not master of your paltry property?" Very well, what is that to me? "Am I not master of exile or bonds?" Again I yield up to you all these things and my whole paltry body itself, whenever you will. Do make trial of your power, and you will find out how far it extends.

Who is there, then, that I can any longer be afraid of? Shall I be afraid of the chamberlains? For fear they do what? Lock the door in my face? If they find me wanting to enter, let them lock the door in my face!—Why, then, do you go to the gate of the palace?—Because I think it fitting for me to join in the game while the game lasts.—How, then, is it that you are not locked out?—Because, if anyone will not receive me, I do not care to go in, but always I wish rather the thing which takes place. For I regard God's will as better than my will. I shall attach myself to Him as a servant and follower, my choice is one with His, my desire one with His, in a word, my will is one with His will. No door is locked in my face, but rather in the face of those who would force themselves in. Why, then, do I not force myself in? Why, because I know that within nothing good is distributed among those who have entered. But when I hear someone called blessed, because he is being honoured by Caesar, I say, "What is his portion? Does he, then, get also a judgement such as he ought to have for governing a province? Does he, then, get also the ability to administer a procuratorship? Why should I any longer push my way in? Somebody is scattering dried figs and nuts; the children snatch them up and fight with one another, the men do not, for they count this a small matter. But if somebody throws potsherds around, not even the children snatch them up. Governorships are being passed around. The children shall see to that. Money. The children shall see to that. A praetorship, a consulship. Let the children snatch them up; let the children have the door locked in their faces, take a beating, kiss the hands of the giver, and the hands of his slaves. As for me, it's a mere scattering of dried figs and nuts." But what, then, if, when the man is throwing them about, a dried fig chances to fall into my lap? I take it up and eat it. For I may properly value even a dried fig as much as that. But neither a dried fig, nor any other of the things not good, which the philosophers have persuaded me not to think good, is of sufficient value to warrant my grovelling and upsetting someone else, or being upset by him, or flattering those who have flung the dried figs among us.

Excerpt from Chapter VII, Of freedom from fear, in Book IV of Epictetus' Discourses.

/misc | Dec 11, 2017


Subscribe or visit the archives