This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
action:Get_File_Attribute [2016/03/10 03:40] AlainLifchitz add link to forum |
action:Get_File_Attribute [2018/03/26 20:17] JMichaelTX ADD link to Filter action. |
||
---|---|---|---|
Line 1: | Line 1: | ||
- | The Get File Attribute action captures the specified attribute for the specified file to a Variable. | + | ====== Get File Attribute Action ====== |
+ | |||
+ | The //Get File Attribute// action returns the specified attribute for the specified file to a Variable. | ||
Click the File Chooser button to the right of the action to select an existing file on disk. Option-click on the File Chooser button to show the currently selected file in the Finder (assuming it exists already). | Click the File Chooser button to the right of the action to select an existing file on disk. Option-click on the File Chooser button to show the currently selected file in the Finder (assuming it exists already). | ||
Line 5: | Line 7: | ||
The result of the action is displayed at the bottom of the action. | The result of the action is displayed at the bottom of the action. | ||
- | File attributes available: | + | ===== File attributes available ===== |
*file type (r/o). | *file type (r/o). | ||
Line 32: | Line 34: | ||
*base name (r/o). | *base name (r/o). | ||
*extension (r/o). | *extension (r/o). | ||
+ | |||
+ | ===== Addition File Attributes ===== | ||
+ | |||
+ | There are several more attributes available using the [[action:Filter|Filter]] [[:Actions|Action]]. | ||
+ | |||
+ | * Get or delete the last path component or the path extension. | ||
+ | * Get the basename of the path (ie the name without directory or extension). | ||
+ | * Expand Path to full page, replacing tilde (~) in the path. | ||
+ | * Resolve symlinks, or standardize the path. | ||
+ | |||
===== See Also ===== | ===== See Also ===== | ||
Line 40: | Line 52: | ||
* [[action:Set File Attribute|Set File Attribute]] | * [[action:Set File Attribute|Set File Attribute]] | ||
+ | * [[action:Filter|Filter]] | ||
* [[:Actions|See all Actions]] | * [[:Actions|See all Actions]] | ||
Line 48: | Line 61: | ||
- [[https://forum.keyboardmaestro.com/t/getting-url-of-most-recently-added-file-to-folder/2902/3|Getting url of most recently added file to folder]] | - [[https://forum.keyboardmaestro.com/t/getting-url-of-most-recently-added-file-to-folder/2902/3|Getting url of most recently added file to folder]] | ||
- | - [[https://www.google.fr/search?q=site:forum.keyboardmaestro.com+Get+File+Attribute|Keyboard Maestro Forum topics about Get File Attribute]] | + | - [[https://forum.keyboardmaestro.com/search?q=Get%20File%20Attribute|Keyboard Maestro Forum topics about Get File Attribute]] |