aboutsummaryrefslogtreecommitdiffstats
path: root/railties/guides/source/active_support_core_extensions.textile
diff options
context:
space:
mode:
authorXavier Noria <fxn@hashref.com>2010-02-07 22:01:54 +0100
committerXavier Noria <fxn@hashref.com>2010-02-07 22:01:54 +0100
commitd91ac89ab83735ad1149907e942c2b0d67e03a56 (patch)
tree95de6489a471e5e07f2dab2d2df82d2eca2ff328 /railties/guides/source/active_support_core_extensions.textile
parent81e779a0191c824f3e4c0df23736bdadb052ac7c (diff)
downloadrails-d91ac89ab83735ad1149907e942c2b0d67e03a56.tar.gz
rails-d91ac89ab83735ad1149907e942c2b0d67e03a56.tar.bz2
rails-d91ac89ab83735ad1149907e942c2b0d67e03a56.zip
AS guide: specifies that renaming a file is atomic on POSIX systems
Diffstat (limited to 'railties/guides/source/active_support_core_extensions.textile')
-rw-r--r--railties/guides/source/active_support_core_extensions.textile2
1 files changed, 1 insertions, 1 deletions
diff --git a/railties/guides/source/active_support_core_extensions.textile b/railties/guides/source/active_support_core_extensions.textile
index 4f7c0c56e2..2d05e66307 100644
--- a/railties/guides/source/active_support_core_extensions.textile
+++ b/railties/guides/source/active_support_core_extensions.textile
@@ -2118,7 +2118,7 @@ File.atomic_write(joined_asset_path) do |cache|
end
</ruby>
-To accomplish this +atomic_write+ creates a temporary file. That's the file the code in the block actually writes to. On completion, the temporary file is renamed. If the target file exists +atomic_write+ overwrites it and keeps owners and permissions.
+To accomplish this +atomic_write+ creates a temporary file. That's the file the code in the block actually writes to. On completion, the temporary file is renamed, which is an atomic operation on POSIX systems. If the target file exists +atomic_write+ overwrites it and keeps owners and permissions.
WARNING. Note you can't append with +atomic_write+.