Tag Info

Hot answers tagged

129

┌── ln(1) link, ln -- make links │ ┌── Create a symbolic link. │ │ ┌── the path to the intended symlink │ │ │ can use . or ~ or other relative paths │ │ ┌─────┴────────┐ ln -s /path/to/original /path/to/symlink └───────┬───────┘ └── the path to the original ...


33

You can't avoid them. They're created to store file information that would otherwise go into an extended attribute on HFS+ (Apple native) or Unix/UFS volumes; in earlier Mac OS this would be the resource fork. Finder file operations will create them automatically to store the icon information, plus Time Machine stores some information in them so if you ...


23

The quote marks are preventing ~ from being expanded to your home folder, so you need to either quote just the part with the space in it: ln -s ~/"Foo Bar/" Foo Note: exactly how much is quoted doesn't matter, as long as the space is in the quoted portion and the ~ isn't. ~/Foo" "Bar/, ~"/Foo Bar/", ~/Fo"o B"ar/ etc are all equivalent. You could also use ...


20

I found the culprit ! Thanks to the suggestion of @Mark Thalkman I made a DTrace script to monitor applications accessing that file. The application that creates the file is called AppWrapper. The way I discovered it was to look at the folders created in October in /Library/Application Support. There were only two, appWrapper and eSellerate. So I ...


20

Zipping from the Finder adds a folder __MACOSX, invisible on Macs, that contains OS X resource forks like custom icons and such. From Wikipedia: The resource fork is a fork or section of a file on the Apple Mac OS operating system used to store structured data along with the unstructured data stored within the data fork. A resource fork stores ...


15

The command is called ln. If used with the option -s it will create a symbolic link in the current directory: ln -s /any/file/on/the/disk linked-file


13

Hallelujah! I figured it out. Okay, so first thing I did was create a new account, as suggested by another answer. The problem did not occur in there, so clearly the problem was limited to my account. I then went into Safe Mode into my account. The problem did not occur as well. So clearly something was loaded in normal mode but not in safe mode that was ...


12

It's generally safe, though a little dangerous depending, to do it but often not worth the effort. The caches in /System/Library/Caches are generally small and useful, the ones in /Library/Caches are less system caches and much more readily cleared. If you have a look in ~/Library/Caches you will find a bunch of applications have a cache in there, none of ...


10

In a nutshell, how would one access this feature in Finder – not Spotlight (Command+Space) – but the adding of tags themselves? From Finder, highlight a file and hit Cmd-I (or right click and select Get Info) to bring up the File Info Dialog for the file. In this dialog the Spotlight Comments field is where you add tag data. Just add text to this field ...


9

Purposes of .DS_Store and ._ files http://diigo.com/0qiwp for an annotated view of http://lists.apple.com/archives/applescript-users/2006/Jun/msg00180.html where Matt Deatherage (a former engineer at Apple) offers explanations. Since I have seen loss of user data (document content) where ._ counterparts are prevented or lost, I agree that it's: not ...


9

You might not be able to track the process that wrote that file, but why not try. Grab a copy of fseventer or search for that filename in the Time Machine spotlight field to see if you can narrow down when it arrived on your Mac.


9

This was changed in Lion along with the introduction of Auto Save and Versions. Save As is still available by holding ⌥ alt whilst in the menus.


8

mdls lists file metadata. A sample below for a folder kMDItemContentCreationDate = 2011-11-20 04:05:42 +0000 kMDItemContentModificationDate = 2014-10-22 01:52:53 +0000 kMDItemContentType = "public.folder" kMDItemContentTypeTree = ( "public.folder", "public.directory", "public.item" ) kMDItemDateAdded = ...


8

This answer may not really answer the question but provide some information what might had happened. I've downloaded the torrent with 4Chan pictures containing the Pain.jpg and two other pics with hebrew chars. Here is the diabolic culprit ;-) ls -aBeil shows: mymac:Reactions user$ ls -aBeil ls: P ͎̮͉͍ͨ̈́̾̈́A ͎̮͉͍ͨ̈́̾̈́I ͎̮͉͍ͨ̈́̾̈́N ͎̮͉͍ͨ̈́̾̈́.jpg: ...


7

This can be done by using the "New Text Document Here" action Select folder -> tab -> start typing "New" -> select "New Text Document Here" -> type name -> enter. If you're looking for a more complete solution that can create any type of file (including ones without the .txt extension that the New Text Document action forces) try this Applescript. Just put ...


6

387,037,139 bytes is the sum of the file lengths in bytes. A file however uses whole blocks on disk, hence even a one byte file takes one block. On the partition on which I tested this, a block is 4K. The “on disk” value is the number of blocks times the block size. The difference between 684 and 716.9 is a factor of 1.024*1,024, that is the difference ...


6

There are many things you can try to fix this: Trashing com.apple.finder.plist, com.apple.systemuiserver.plist and com.apple.loginwindow.plist (they will be recreated when you launch Finder) in ~/Library/Preferences and Force Quit Finder Turning off Calculate All Sizes in Finder Turning off Show View Options in Finder Another thing you can try, is to ...


6

You are right, vanilla Unix doesn't support this. But there is this thing called ACL (Access Control Lists) which allows for a much more granular definition of access rights than the usual user/group/world rights. From Wikipedia: Most of the Unix and Unix-like operating systems (e.g. Linux, BSD, or Solaris) support POSIX.1e ACLs, based on an early POSIX ...


6

h.264 encoded video, AAC audio. Both standards of MPEG 4.


6

Unfortunately, you just have to remember to do it each time you make a file or directory. There's no way you can do this via software tools or by formatting to a particular file system. After the fact you can use software to convert spaces to '.' or '-' however. Obviously what you describe is an excellent idea and good practice when working in a *nix ...


6

There's no disk letter in OS X unlike Windows. The mount point for disks is usually /Volumes. For example, files on a flash drive with the name FLASHDRIVE will be located in /Volumes/FLASHDRIVE/. The startup disk is the root, /. Therefore, the Users folder is /Users. No drive letter is prepended to this.


6

Thought I threw my two cents in. Being both a Mac and Linux user - I find that once a SAMBA share is created on a Linux machine (browseable option on Linux samba turned on with or without a login - you can "connect as" from the Mac to the Linux machine), my Mac would pick it up and list in on Finder's left pane. Here's a quick SAMBA setup for the Linux ...


6

Being pretty unfamiliar with batch files, I'm not sure of the functionality available, but there are two main scripting methods on OS X which are similar: AppleScript AppleScript is a scripting language which lets you control OS X and many applications. AppleScripts are generally easy to understand and write whilst providing a lot of advanced ...


6

VideoLAN's VLC is the way to go here, I haven't found a movie file that it can't play.


6

You can run the shell command /usr/bin/textutil in the Terminal.app found in /Applications/Utilities/ textutils Can be used to convert the text from one format to another. But it also can "Read the specified files, concatenate them, and write the result out as a single file in the indicated format." /usr/bin/textutil file/s -cat convert to format ...


5

Run this command to copy /bin/sh from the BaseSystem.dmg on the Recovery HD: diskutil mount Recovery\ HD && hdiutil mount /Volumes/Recovery\ HD/com.apple.recovery.boot/BaseSystem.dmg && sudo cp -p /Volumes/OS\ X\ Base\ System/bin/sh /bin/sh Also see How can I get back a system file after deleting it from my Mac?


5

Beware : once you change the content of a torrent, you're not able to seed it anymore. Open a finder window, search for all files named .dat then just press cmd+a (select all) then cmd+backspace (delete) then cmd+backspace+maj (empty the bin) edit You can use gemini to find duplicates then delete its with finder or if you're familiar with bash : find ...


5

I had the same problem, but none of the fixes above helped. This finally did: http://blog.hsoi.com/2014/02/25/my-slow-mac-mavericks-coreservicesd-iconservicesagent-and-how-fs_usage-saved-me/ Some issue with an application (in my case Xcode) and icons. Try this command in Terminal, which reports realtime filesystem activity from the IconServicesAgent: ...


5

You can easily build this yourself with some shell commands: find ~ -type f -exec md5 -r '{}' \; > /tmp/md5.list will build a list of md5 hashes over all your files. grep $(md5 -q FILE-TO-SEARCH) /tmp/md5.list will search for the md5 hash of FILE-TO-SEARCH Running the first command (especially if you run it across the whole disc) will take a long ...


5

You might also use fdupes. It doesn't have an option to search for duplicates of a specific file, but you can just grep the output for the filename: fdupes -r1 .|grep filename -r recurses into directories and -1 prints each group of duplicate files on a single line. Other useful examples: fdupes -r . finds all duplicate files under the current ...



Only top voted, non community-wiki answers of a minimum length are eligible