The truth of WordPress revision management

It seems that many people disable the revision feature of WordPress. But is it what you really want? If you learn what WordPress really do and take care of them, the revision feature will be certain benefit to you. In a default environment, WordPress works as follows. A post has only one autosaved revision at most. How revisions are made when you preview depends on post status. Revisions are made only in the wp_posts table. When you bulk edit posts, revisions are made. When you quick edit posts, revisions are made, too. The time of loading posts in permalinks is not proportional to the number of posts and revisions. I’ll [Read the Rest...]

How to make git-diff ignore specific lines

Recently I use git for versioning Cisco router/switch configurations. One problem here is the ‘ntp clock-period’ line. Cisco equipments have a clock adjustment value for NTP in their configuration and its value changes without any manual configuration changes. So even though I have made no changes in their configuration, git-diff shows lines like following. -ntp clock-period 36027555 +ntp clock-period 36027579 Because it will be adjusted automatically, usually no need to save an updated value. So I want them disappear when I do git-diff. The git-diff has ‘-G’ option to show changes matched with regex. But it has no option to avoid matched lines. Generally in such a situation, we use [Read the Rest...]

Git and Windows Shared Folders

With the msysGit package (Git for Windows), we can use Git easily under Windows environments. Even if you want repositories on Windows servers, you can make it in shared folders. Yes, you need only shared folders instead of running git-daemon on your server. When you manipulate repositories on shared folders, you can use a syntax bellow to identify the repository without mapping the shared folder as a drive. //servername/folder/subfolder/repository If you want to create a new empty bare repository on a server. $ git init –bare //server/folder/git/myproj.git If you want to clone your local repository to a new bare repository on a server. $ git clone –bare myproj //server/folder/git/myproj.git When [Read the Rest...]