It isn't only #changeDirectory: method that is missing. Method #workingDirectoryPath: and instance variable workingDirectory are also missing.��
FileSystem >> changeDirectory: aPath
�� self workingDirectoryPath: (self resolve: aPath)
FileSystem >> workingDirectoryPath: aPath
�� aPath isAbsolute
�� �� ifFalse: [ self error: 'Cannot set the working directory to a relative path' ].
�� workingDirectory := aPath
To solve my problem, I implemented those and also fixed #initializeWithStore: and changed #workingDirectoryPath
FileSystem >> initializeWithStore: aStore
�� store := aStore.
�� workingDirectory := store defaultWorkingDirectory
FileSystem >> workingDirectoryPath
�� ^ workingDirectory
Those are from Pharo 5. However, this breaks Monticello (when opening Monticello Browser). A FileSystem instance has instance variable workingDirectory set to nil. This should be impossible. I set 'self halt' in #initializeWithStore:. It doesn't get triggered, which tells me the instance isn't created by normal way. I don't know what's going on there.
To fix it, I changed #workingDirectoryPath to
FileSystem >> workingDirectoryPath
�� workingDirectory ifNil: [
�� �� workingDirectory := store defaultWorkingDirectory ].
�� ^ workingDirectory
That solves my problem, but this is a specific tool. I don't know what other problems those changes will cause. This #ifNil: guard is not in Pharo 5, so that makes me worry. In general, the change in FileSystem gives impression that the it is intentional. But I haven't found the new Pharo 6.1 way to change working directory, if there's any.
--
Andreas