Re: Write to file Entitlement

2011-11-04 Thread Sam Rowlands
Rowlands s...@ohanaware.com http://www.ohanaware.com - Fun Photos, HDRtist Pro & some cool free apps. On Nov 1, 2011, at 2:06 AM, cocoa-dev-requ...@lists.apple.com wrote: > Date: Mon, 31 Oct 2011 08:10:57 -0700 > From: James Merkel > Subject: Re: Write to file Entitlement > To: Gideon King

Re: Write to file Entitlement

2011-11-02 Thread Shane Stanley
On 02/11/2011, at 6:19 AM, James Merkel wrote: > Your're assuming the temporary exception will always be granted. A point seemingly made clear in today's email on the topic: "These entitlements are granted on a short-term basis and will be phased out over time." -- Shane Stanley 'AppleScript

Re: Write to file Entitlement

2011-11-02 Thread Sean McBride
On Tue, 1 Nov 2011 11:00:33 -0700, James Merkel said: >Why would someone want to base their application on the tenuous >availability of a temporary exception ? Because there's no choice. They are the only way to achieve a large number of extremely common operations. I'm looking forward to seei

Re: Write to file Entitlement

2011-11-01 Thread Seth Willits
On Nov 1, 2011, at 12:19 PM, James Merkel wrote: >> Well, I maintain a synchronization tool. For me, that seems like a >> reasonable solution. Each time the user decides to synchronize 2 folders, I >> could just use a temporary exception. > > Your're assuming the temporary exception will always

Re: Write to file Entitlement

2011-11-01 Thread James Merkel
On Nov 1, 2011, at 11:37 AM, Laurent Daudelin wrote: > On Nov 1, 2011, at 11:00, James Merkel wrote: > >> Why would someone want to base their application on the tenuous availability >> of a temporary exception ? >> >> Jim Merkel >> >> On Nov 1, 2011, at 10:30 AM, Laurent Etiemble wrote: >>

Re: Write to file Entitlement

2011-11-01 Thread Laurent Daudelin
On Nov 1, 2011, at 11:00, James Merkel wrote: > Why would someone want to base their application on the tenuous availability > of a temporary exception ? > > Jim Merkel > > On Nov 1, 2011, at 10:30 AM, Laurent Etiemble wrote: > >> Hello, >> >> In a sandboxed application, you can read/write fi

Re: Write to file Entitlement

2011-11-01 Thread James Merkel
Why would someone want to base their application on the tenuous availability of a temporary exception ? Jim Merkel On Nov 1, 2011, at 10:30 AM, Laurent Etiemble wrote: > Hello, > > In a sandboxed application, you can read/write files without the save dialog > by using the "File Access Tempora

Re: Write to file Entitlement

2011-11-01 Thread Laurent Etiemble
Hello, In a sandboxed application, you can read/write files without the save dialog by using the "File Access Temporary Exceptions" (cf. http://developer.apple.com/library/mac/#documentation/Miscellaneous/Reference/EntitlementKeyReference/AppSandboxTemporaryExceptionEntitlements/AppSandboxTemporar

Re: Write to file Entitlement

2011-10-31 Thread Martin Hewitson
I wonder how such a system would work with an app which is a file-manager. Take, for example, Xcode. How could such an app be sandboxed if that would stop it from being able to save the files it manages? Has such a scenario been thought about or discussed before? Cheers, Martin On 31, Oct, 2

Re: Write to file Entitlement

2011-10-31 Thread James Merkel
That will completely break my app. Off the top of my head, I don't know how I would change things to conform to that regime. I update files in a batch mode. Jim Merkel On Oct 30, 2011, at 11:39 PM, Gideon King wrote: > If you are writing to somewhere inside the sandbox, you can read and write

Re: Write to file Entitlement

2011-10-30 Thread Gideon King
If you are writing to somewhere inside the sandbox, you can read and write freely, but if outside, then you have to go through the save panel, which behind the scenes stretches your sandbox to include that file. Regards Gideon On 31/10/2011, at 3:27 PM, James Merkel wrote: > Reading the san

Write to file Entitlement

2011-10-30 Thread James Merkel
Reading the sandboxing documents, it looks like in order to write to a file you need to use the save dialog. My app updates files without the save dialog. Will that be permitted in a sandboxed app ? Jim Merkel ___ Cocoa-dev mailing list (Cocoa-dev@list

Re: Write to file.

2008-12-24 Thread Macarov Anatoli
Thank you for your reply and for directory /tmp. Вы уже с Yahoo!? Испытайте обновленную и улучшенную. Yahoo! Почту! http://ru.mail.yahoo.com ___ Cocoa-dev mailing list (Cocoa-dev@lists.ap

Re: Write to file.

2008-12-23 Thread John Cebasek
Well, it's been a long time since I worked on a loginwindow replacement, but I think it was when Tiger was released, I had to split my code into two mechanisms , one privileged - which could have no GUI, and could write to at least /tmp and the global Preferences directory and then a non-pr

Write to file.

2008-12-23 Thread Macarov Anatoli
CFPreferences doesn't work. My bundle works in login window under user account securityagent. Can I somehow with the user's rights create file? Вы уже с Yahoo!? Испытайте обновленную и улучшенную. Yahoo! Почту! http://ru.mail.yahoo

Re: Write to file.

2008-12-16 Thread Jean-Daniel Dupas
Le 16 déc. 08 à 13:47, Macarov Anatoli a écrit : I have admin rights. But I can't use NSUserDefaults because upon starting system in login window I'm not in user account, and there the function doesn't work.. After authorization and login in user account the function will work because det

Write to file.

2008-12-16 Thread Macarov Anatoli
I have admin rights. But I can't use NSUserDefaults because upon starting  system in login window I'm not in user account, and there the function doesn't work.. After authorization and login in user account the function will work because detects what user account you work from.

Re: Write to file.

2008-12-15 Thread Filip van der Meeren
You are writing to a folder that is under admin rights. Instead write to the user directory: ~/Library/Preferences/myFile.plist Or make use of the NSUserDefaults class. Filip van der Meeren fi...@code2develop.com http://www.sourceforge.net/projects/perlmanager http://www.sourceforge.net/projects/

Write to file.

2008-12-15 Thread Macarov Anatoli
I have got my own bundle that I insert into login window. When login window is started up  the bundle  writes necessary parametr into file which is situated  in /Library/Preferences/. I try to write in the following way: NSString *Value;        NSDictionary *theDict = [NSDictionary dictionaryWit

Re: to write to file except NSData*

2008-04-15 Thread Jens Alfke
On Apr 15, 2008, at 10:38 AM, Nick Rogers wrote: but i want to write the length of (NSData *)data, before I write it to file because I will be writing a lot of NSData to the file, so that I will be able to read the length first and then read the following NSData. SO how can I write the lengt

Re: to write to file except NSData*

2008-04-15 Thread Alastair Houghton
On 15 Apr 2008, at 16:06, Navneet Kumar wrote: ok, so if i generate a header NSData object and write that to file, and then then write the larger NSData object, how will i read one NSData after the another. How will i know what length should I read. excuse me if this sounds very newbie to yo

Re: to write to file except NSData*

2008-04-15 Thread Jeff LaMarche
On Apr 15, 2008, at 10:38 AM, Nick Rogers wrote: Hi, I am creating a file with: NSFileManager *fileManager = [NSFileManager defaultManager]; [fileManager createFileAtPath:path contents:nil attributes:nil]; === then I got a fileHandle as: NSFileHandle *fileHandle = [NSFileHandle fileHan

Re: to write to file except NSData*

2008-04-15 Thread Navneet Kumar
ok, so if i generate a header NSData object and write that to file, and then then write the larger NSData object, how will i read one NSData after the another. How will i know what length should I read. excuse me if this sounds very newbie to you. Wishes, Nick On 15-Apr-08, at 8:30 PM, Alast

Re: to write to file except NSData*

2008-04-15 Thread Alastair Houghton
On 15 Apr 2008, at 15:49, Nick Rogers wrote: I will use NSKeyedArchiver to create a lot of NSData objects before writing to file. I can't write one whole NSData to file because i have to write in GBs and also have to show the progress bar. So just use NSKeyedArchiver to generate a header be

Re: to write to file except NSData*

2008-04-15 Thread Nick Rogers
Hi, I will use NSKeyedArchiver to create a lot of NSData objects before writing to file. I can't write one whole NSData to file because i have to write in GBs and also have to show the progress bar. Thanks for the reply, Nick On 15-Apr-08, at 8:10 PM, Thomas Backman wrote: Sorry to duck yo

Re: to write to file except NSData*

2008-04-15 Thread Thomas Backman
Sorry to duck your question, but are you sure you don't want NSKeyedArchiver and similar classes? /Thomas On Apr 15, 2008, at 4:38 PM, Nick Rogers wrote: Hi, I am creating a file with: NSFileManager *fileManager = [NSFileManager defaultManager]; [fileManager createFileAtPath:path contents:nil

to write to file except NSData*

2008-04-15 Thread Nick Rogers
Hi, I am creating a file with: NSFileManager *fileManager = [NSFileManager defaultManager]; [fileManager createFileAtPath:path contents:nil attributes:nil]; === then I got a fileHandle as: NSFileHandle *fileHandle = [NSFileHandle fileHandleForWritingAtPath:path]; === NSFileHandl