IMHO this beats cloud storage

This is an old-school command, but I find that it is still way better than cloud storage for sharing a directory between two or more systems:

rsync [options] source destination

If you’re using Cygwin under Windows, then the command would most likely be:

rsync -rv --size-only --delete spectra:~/edu/ ~/edu/


On my other machine, called spectra, which I was doing homework on earlier today at the cafe, I have a directory under my home (C:\Users\me) named edu. I also have a directory named edu on my home system.

After working at the cafe, when I come home I want to sync the edu directory with my home system.

Now of course one way to do this would be to use a cloud storage system like Dropbox (or even much better would be Owncloud). But the thing is, I have found that actually for something like basic syncing of a directory, cloud storage is way overkill. You have to have a client running all the time on both systems, constantly monitoring the filesystem, and I’ve just seen too many slowdowns because of this when working heavily in synced directories.

Another serious issue is sync latency. Ok you may have a directory set up under cloud storage, but how often does the client running on your machine actually sync it with the cloud? Its not instantaneous. It can be intervals of time as long as 15 minutes. And what if it didn’t sync before you need to access it on the other computer? Also, how do you even know if it already synced, without checking the log of the sync client?

And one final consideration is network traffic. If you’re at a cafe working, do you really need to be pushing syncs to your cloud while you’re working, using up bandwidth? I don’t need to sync until I’m actually done working. In fact I don’t really even want to sync before then. Its kind of silly because I’m still working on files, editing them, creating or deleting them. Its kind of a waste to sync until I’m actually finished with my work.

All of which thus leads to: rsync. rsync is oldschool and is a really clean, highly efficient, and basically the most excellent tool for syncing directories between two machines.

To repeat the above command:

rsync -rv --size-only --delete spectra:~/edu/ ~/edu/

let me explain what’s going on.

First, I’m using the -r and -v switches. -r means be recursive, that is sync everything below the current level. This is necessary when syncing a directory. If you are only syncing one file, then you don’t need -r. Otherwise you do.

-v means be verbose. Whatever is being synced will be listed on the screen. When syncing a really large directory then sometimes -v can be omitted, but otherwise its nice to actually see what the command is doing.

–size-only is specific to Windows. This has to do with the way rsync compares files to determine whether or not they need to be synced, which is different on Linux filesystems than Windows. Under Linux –size-only would not be necessary because rsync can effectively compare the local and remote files to determine whether or not they are the same. But with Windows it can’t so easily. It needs the –size-only option unfortunately. I wish this were not so, and it does represent a slight degradation of rsync, but it still works.

Now let’s say that I’m about to go out to do my homework, and I can’t remember if I synced the edu directory of my home system with spectra. Then I can easily do a test run of rsync to see if it would actually sync anything:

rsync -rvn –size-only –delete ~/edu/ spectra:~/edu/

The -n switch means do a dry (test) run. No files are actually transferred but, because the -v switch is used, it will show if any files actually would be transferred.

There is one final important aspect of the syncing which I did not yet cover, which is indicated by the –delete switch. The –delete switch is potentially dangerous but also powerful. It tells rsync to delete any files on the destination which are not on the source.

Think about this: If I’m at the cafe working and I decide to rename some documents, then when I get home I am going to sync spectra to my home machine. If I don’t use the –delete switch then it will sync the renamed copies of the documents, and the copies with the old names will still remain on the home system. This would not be good. So using –delete it will delete the non-renamed copies of the files and make sure that the contents of the edu directory on both machines is exact.

And of course if you haven’t set up Cygwin then you definitely should. (If you’re on a Mac then you don’t need Cygwin and can install rsync fairly easily in a console.) You will also need to have ssh (OpenSSH) setup on both systems since that is used for the file transfer.

It may seem cumbersome to many people to set this stuff up and learn how to use it, but there are certain basic operations related to information processing which it turns out are most efficient when done via a command line. This is related to the fact that we humans use words and that the way we perform functions on data is based on text.

Nothing is more powerful, flexible, and efficient as using rsync to keep directories in sync, and the benefit of knowing how to use it will extend into many other things.

Laissez-faire vs. fascist

Laissez faire, telle devrait être la devise de toute puissance publique, depuis que le monde est civilisé … Détestable principe que celui de ne vouloir grandir que par l’abaissement de nos voisins! Il n’y a que la méchanceté et la malignité du coeur de satisfaites dans ce principe, et l’intérêt y est opposé. Laissez faire, morbleu! Laissez faire!![4]

(Trans: “Let it be, that should be the motto of all public powers, since the world was civilized … That we cannot grow except by lowering our neighbors is a detestable notion! Only malice and malignity of heart is satisfied with such a principle and our (national) interest is opposed to it. Let it be, for heaven’s sake! Let it be!) Laissez-faire

There is news recently about how the FBI has obtained a court order to force Apple Inc. to provide them with a custom firmware for the iPhone 5s which does not contain built-in protections against password cracking.

Today it is in the news that Donald Trump is criticizing Apple over its decision to fight this court order.

What is going on here is that the government is trying to force Apple to essentially give a master key to the FBI which will be possible to use on millions of devices, not just the one in question. That is wrong. The government is trying to force Apple to deliberately severely cripple one of its products.

I don’t understand what is in the mind of Donald Trump on this. I thought the Republican party was supposed to represent laissez-faire market values, not fascism. It seems like a Democrat thing to try to force Apple to deliberately break its products so that the FBI can attempt to break in to a phone of someone who is already dead.

Yeah, that’s another thing. As someone mentioned in another forum, the people who committed the crimes are already dead. Now they are thrashing the corpses. It seems like their real motive in doing so is not for justice but as a convenient tool for a power grab.

By the way, if you follow this line of action on the government’s part to its full conclusion, it reaches a point of complete absurdity. It goes like this:

Company makes a phone which provides encryption security.
Government tries to force company to deliberately weaken or destroy the encryption feature.
Company makes new products which it is impossible to even be able to weaken the encryption.
Government makes that illegal.

Now we are into black market territory or territory where people find some ways to mod their devices.

What the government does next could be a couple of things: They could forbid any phone carrier to allow a black market device to be activated on their networks. Or, going a step further, they could force all phone manufacturers and carriers to only create and allow activation of whitelisted devices.

And if it reached that point, you’d have to ask what the fuck is the government doing? Is this what government is supposed to do? Is this what people expect their government to do?

No rational human would think so. Its absurd. But that is the logical endpoint of where this cat-and-mouse game goes.

The basic bottom line is that one person has the right to create and give a device to another person and the government has no business whatsoever getting involved in it. What the government is saying is “We have a right to know X, because it exists. Furthermore, if device A contains X, we have a right to force the manufacturer of A to alter A to enable us to access X. Because X exists.”

That kind of logic is purely grotesque and sick, and represents an utter disregard for some of the most basic, universally accepted human rights. It is an abject disregard for basic freedoms which our government should be upholding, not destroying.

So, fuck you to the government and fuck you to Donald Trump and other politicians for thinking and acting like fucking fascists. Your job is to uphold freedom, not destroy it.

Humans split from chimps 8 MYA not 6 MYA

A new paper has come out which announces the finding by a team of paleoanthropolgists who studied the age of sediments surrounding fossils of the common ancestors between humans, chimps, and apes. The date at which humans split from chimps has been pushed back by 2 million years to 8 million years ago. The date at which humans and chimps split from apes has also been pushed back by 2 million years to 10 million years ago. Fossil analysis pushes back human split from other primates by two million years

Ecotopia got invaded

I was just reading this Wikipedia page about the book The Nine Nations of North America. It describes the different regions and one of them is called Ecotopia:

Ecotopia — the Pacific Northwest coast west of the Cascade Range and the Coast Mountains, as well as several Alaskan Pacific Coast Ranges, stretching from Alaska down through coastal British Columbia, Washington state, Oregon, and into California just north of Santa Barbara. Capital: San Francisco.

Then there is another region called, ominously, Mexamerica:

Mexamerica — the southern and Central Valley portions of California as well as southern Arizona, the portion of Texas bordering on the Rio Grande, most of New Mexico, northern Mexico, and the Baja California Peninsula. Capital: Los Angeles.

Ecotopia and Mexamerica are about as opposite as its possible to get. One culture venerates macho dumbfucks who want to drive around in oversized pickups with holes drilled in the mufflers, while the other is about having a light footprint and living consciously.

One culture has perverted lowlifes who stalk, sexually harass, and rape women. The other is about evolving to levels of self-actualization where there is respect for the sanctity of all living things.

These cultures do not mix well. An ecologically-conscious person who is riding a bicycle along a street does not like getting blasted out by the outrageously loud noise of some macho dumbfuck in a pickup with holes drilled in the muffler.

People hanging out together at a nude beach on a sunny day do not like to have a group of disgusting perverts in the distance constantly ogling them as they booze it up.

There is even the issue of the drugs that the Mexamericans bring in such as meth, cocaine, and crack, vs. the more holistic drugs like LSD and psilocybins that are part of Ecotopia. And while one group may appreciate its ganja, the other is busy ecologically raping public forest lands to set up military-style guerilla growing operations and spewing toxic chemicals into streams.

At least the southern part of Ecotopia has since been severely invaded and taken over by Meximerica and by an entirely other thing: Asia. Its really sad to see it lost, and people should stand up against the oligarchy’s complete betrayal of Ecotopia.

Presently there is only one candidate running for President of the United States who is advocating policies which would protect Ecotopia against the oligarchy’s betrayal: Donald Trump.

Many people, including myself, are reluctant to support a Republican, but the betrayal by the Democrat party has been so severe. We do not know what Mr. Trump’s stand would be for key environmental issues – such as support for organic agriculture, labelling of GMO’s, and limits on fracking and shale oil mining. His policies could be horrendous. Or not. As far as I know no one has really asked him about these issues and he has not spoken about them at length as he has other issues.

On one hand he could allow things to continue more-or-less as the status quo. Whether that would be acceptable or not I don’t know. But it is also possible that he could enact policies which were much worse. Or he might even enact policies which were better. Perhaps he would recognize that the campaign to trample on organics is part of the oligarchy’s plan and put a stop to it.

Unfortunately we are in a terrible position. America is really being methodically ripped apart by the oligarchy and its heartbreaking to watch. I am still going to support Donald Trump because the swarms of illegal immigrants invading America is absolutely outrageous and he is at least standing up against the oligarchy.

There are so many illegals in America that students – myself included – cannot enroll in courses they want at community colleges. Businesses are hiring illegals with impunity and city governments are openly violating federal law.

Its sad, but its like people in Ecotopia are in some kind of delusional state and not standing up to protect what they have. They are not standing up against the invasion because they’ve swallowed the lies that illegal immigration is humanitarian when if fact the opposite is actually true.

People have to stand up and take responsibility to create the kind of world they want. That world will not just happen due to natural forces. It must be created, shaped by actions. Humans are now like engineers of Planet Earth – whether the like it or not, whether they want to accept it and admit it or not. Humans now have the responsibility of engineering the planet and they are going to have to make decisive choices about how Earth should and should not be.

Presently, their lack of responsibility is creating a slow-moving catastrophe which gets worse every day. They are finding out the hard way as things collapse. Even while they often claim to ascribe to noble values, they are watching the actualization of those values in reality get decimated.

Shigeki-niisan was staring at the sky

Ohi sama week 13 ep 078

Shigeki-niisan [brother Shigeki] was staring at the sky. Whether he was thinking about his flights or just staring at the sky I didn’t know. If he took things slowly; if he just took his time I thought that someday his wounds would heal.

The airplane factory my father had been working at had officially closed so he was looking for new work. He regretted the many young men who had lost their lives in the airplanes he had participated in creating. [scene showing father throwing airplane blueprints into a fire] Until his death, my father wouldn’t talk about airplanes again. All three of us felt the same way.

[Yoko (the narrator, who’s also a gradeschool teacher) looks down at textbook with many blacked out lines of text due to post-war censorship, at first with a kind of look of horror. then she looks up at her father standing next to the fire bin, sighs, and slowly begins to smile. she lets out a small laugh and another sigh.]

[Father looks over to Yoko] What is it?

[Yoko] Nothing. I was just thinking about our family.

scene from Ohisama week 13 episode 078

In this drama during the war the Japan was more like North Korea today than modern Japan. Schoolteachers were required to drill militarism into their students and indoctrinate them constantly and it was like the whole society was really brainwashed.

Immediately after the end of the war, teachers were instructed to make their students black out entire sections of indoctrination and jingoism in textbooks which was a shock to all those who had been so deeply brainwashed for so long.

I like the drama’s bare honesty in depicting the way they were shocked and really felt during and after the war. In one scene American soldiers come into their restaurant and offer them tins of food which they flatly reject from the “occupiers”.

If you work with PDF documents often you should read this

PDF documents are so common that its actually difficult to imagine any student or professional today not using them extensively. PDF documents fill a special and important niche in the electronic data revolution. To a very large extent they have (thankfully) replaced bulky (and often ridiculously expensive) textbooks.

Now you can have a library of books which weigh nothing and are easy to manage and can be transferred between devices and transmitted easily.

However, to make the most of working with PDF documents there are some important things to know. One of these is a concept called inheritable zoom. This is a feature which, if you are working with a document – especially a larger one like a textbook where you jump around between chapters and pages often – you will easily notice.

One thing that is obviously important about an electronic document is the actual display of the text and its size. This is the zoom level of the document. Most people will have a certain comfortable zoom level which is usually closely related to the electronic display on which the documents are being viewed. For example, on one laptop I use which has a 15.6″ HD+ (1600×900) display, the perfect zoom level seems to be 146%.

So let’s say you have a document and you open it up to work on it on your system. The initial view is too small so you zoom in to a level where the text is large but not too large. You are now happy with it.

But then you go to a bookmark in the document and suddenly the zoom level changes.  So you manually set the zoom level back to where you had it.  Then later you open another bookmark and jump to another page, only to have the zoom level reset yet again.

This happens when the zoom level is hardcoded into the bookmarks, which is generally a bad idea. A better idea is that the zoom level of bookmarks is inherited, meaning it will stay at whatever the zoom level was set to previously.

This kind of makes logical sense and you would think its obvious, but a surprising number of documents I have worked with do not have inheritable zoom, but rather fixed zoom. The upshot is that you have to keep manually adjusting the zoom level every time you visit a new bookmark (which is annoying).

There is an easy way to fix this, which is the purpose of this post, and I encourage everyone who works with PDF documents on a regular basis to become familiar with it. Here is how:

First you need to get the Open Source tool called JPdfBookmarks (look for the binaries download of the latest version. Download it and unzip it with 7-zip. The run jpdfbookmarks.exe.

From inside JPdfBookmarks open the pdf document that you want to fix. Then under the Tools menu select dump and save the dump file (you can just name it dump.txt or whatever else you want). Now open the dump file in text editor. I highly recommend using Notepad+ – another essential and Open Source app – for a reason that will be apparent in a minute.

Open the dump file in Notepad+ and you will see something like this:


Notice the numbers at the end of each row. Its actually a set of three numbers separated by commas. The last of these numbers is the zoom level. 1.0 means a zoom level of 100%. It is a hardcoded zoom level. Every bookmark that is opened will automatically open at 100% zoom regardless of where you had it set previously. This is not inheritable zoom. It is bad and we don’t want it.

To fix it we need to change 1.0 (or whatever else it might be hardcoded as in your documents) to 0.0. For example, a 130% zoom level would be 1.3. I’ve seen documents where the zoom levels for some bookmarks were values like 0.998 – a close approximation of 100% where the setting must have somehow gotten minced. You will need to look at what the zoom levels are set to at the end of each line, each of which corresponds to a bookmark. Then you will need to do a search and replace so that they all get set to zoom level 0.0.

We can employ the powerful and simple to use search-and-replace tool in Notepad+ to do this. Select Search -> Replace from the menu and you will see the following window:

jpdfbookmarks 2

In the Find what textbox input the hardcoded zoom level of the bookmarks. You will notice that I didn’t just put “1.0” but instead I put “,1.0”. This is to be safe, because the characters “1.0” might occur in some other place in the document that I do not want to change. Even using “,1.0” it is not safe to assume that those characters might not occur somewhere else in the document unrelated to the bookmark zoom level so I always recommend scanning over the document very quickly to make sure.

In the Replace field enter “,0.0”. After scanning the document to verify that “,1.0” (or whatever other zoom level it is that you are replacing) doesn’t occur anywhere else in the text, then select the Replace All button and save the file in Notepad+.

Then go back to the JPdfBookmarks window and select Tools -> Load. Select the dump file that was just saved. Then select File -> Save to save it.

At this point the document has now been partially fixed and the zoom level of all bookmarks is set to inheritable. Now for all of this to make sense a few more things need to be changed. If you’re using Adobe Acrobat then open up the document and go to File -> Properties to open the settings for the document.

Under the Initial View tab look at the settings under Layout and Magnification. When you open the document, do you always want to see the bookmarks in the navigation pane on the left side? (for many textbooks I prefer this, but for book-books I usually don’t) If you do want to see the bookmarks every time, then under Navigation Tab select Bookmarks Panel and Page, otherwise select Page Only.

For the Page Layout setting I recommend Single Page Continuous although you may prefer any of the other settings. Personally I like the documents to scroll similar to the way web pages do, which is what Single Page Continuous is. If you want something more like an e-reader such as Kindle, then select Single Page.

Ok this next setting is the all-important one: Magnification. What is the sweet-spot magnification level on your computer? As I metioned above, on one of my main laptops it is 146%. This then is where to set it.

Now, on another device with a different display and zoom level sweet spot, this can be set to something else. If you want to have the document set to always open at one magnification or the other depending on the system, then it will have to be copied to the other system and a different magnification level will be set there.

If you use a shared document on a network share drive or cloud storage, then obviously you will have to manually change the zoom level when you open the document on the other system or else find a magnification level that you are happy with on both systems.

You could also set the magnification level to Default, Actual Size, Fit Page, Fit Width, Fit Height, or Fit Visible and see how any of these work out for you.

If you are going to be annotating the document then you are probably only going to want to be using one copy, not two different ones. So you can either try to find a common magnification level that works between all your systems or try one of the other settings.

Next in the settings is the Open to page option. I have one document where the cover of the book is the first page and it is an odd size, smaller than the rest of the document. If I have it set to open this cover page as the initial page and have selected the Resize window to initial page option under Window Options its going to be a problem, because the Acrobat window will shrink to the size of the small cover page. Then when I select a bookmark whatever subsequent page is opened will be too large for the window and partially cut off. No good.

So what I do is select a reasonable initial page under Open to page. It could be a second title page that is the same size as other pages, or a table of contents page.

Under Window Options then I would select Resize window to initial page except that if you are going to try playing with something other than a fixed magnification level with a document then you might not want this. If your operating system can remember the size of the window for this document that would be great. However my experience is that Acrobat only remembers the window size of whatever PDF document was open last, not the size of each specific document. At any rate, you can be aware of this and experiment if you like with window size and initial document size. The settings I suggest here are the ones I’ve found to be the least hassle.

Finally, under User Interface Options, you may want to select Hide menu bar and Hide toolbars. If there are only two keyboard shortcuts you remember for Acrobat, those should be F8 and F9. These are the keys to show/hide the Toolbars and the Menu bar. Make sure to save the document after editing the settings.

[The other ultra-important shortcuts to remember are: h – hand tool, v – edit (select) text, spacebar – temporarily toggle hand tool while in text edit, and Ctrl-Shift-n – Go to Page.]

Do you use PDF documents on a tablet or mobile phone? Then I highly recommend ezPDF Reader which is made by a really cool Korean company. For sheet music PDF’s under Android I recommend MobileSheets.

Reference, credit, and thanks to PDF Bookmarks: Change Zoom level and Name of PDF Bookmarks

My prayers go with the people of Tainan

I just heard the news about the earthquake which struck in Tainan. I feel a special affinity for Taiwan, which is very closely connected with Silicon Valley. Taiwan, Japan, South Korea, the Philippines – and Hong Kong also – all have a special affinity with California and its people and I think we should stick closely together and support a free world.

Whenever China tries to convince people that draconian authoritarianism and lack of basic human rights is somehow necessary, I always think of the healthy, thriving democracies in Japan and especially Taiwan as examples of how dead wrong China is.

The #1 Thing to Save Yahoo

Change the name. I don’t know if this is something that has been seriously taken into consideration, whether there have been high-level meetings about this, strategic planning and projections.

But, the name has to be changed. It has to be something that is more business-like. Something that is non-agitating. Like the word blue. Or the word sky. Something like that. Something that people can easily remember and that will be easy to brand around – for example if it were “blue” then obviously there could be all this blue-themed stuff. If it were sky, then sky-themed stuff. I’m not saying use either of these, but something like these. These are the types of names that are popular for companies like Yahoo. But Yahoo is not a good name. Sorry.

Here are a few suggestions:


Obviously many of these are being used, but probably not by any big companies and could probably be acquired for a reasonable sum.

Another idea would be to get inspiration from feng shui. I have heard that feng shui-related changes to things, such as a name, can have dramatic results. Think big. Think of the entire world. Then think of something appropriate that resonates. That is how I would pick a name.

One final idea would be a rearrangement of the word yahoo into something better: perhaps something like hayaho or even more simply: yah or ayah or ayaho. Personally I really like yah and think it would be a really cool and very popular rebranding.

I can already visualize the promotional video and graphic images announcing the rebranding: “Yahoo is now Yah” featuring some Rasta guy saying “Yah man!”.

Page 32 of 97« First...1020...3031323334...405060...Last »