nl_tokens: Rename a file
pl_tokens: function move ( repoState , filepath , newFilepath ) { if ( filepath === newFilepath ) { return repoState ; } const initialWorkingState = repoState . getCurrentState ( ) ; // Create new file, with Sha if possible const sha = WorkingUtils . findSha ( initialWorkingState , filepath ) ; let changeNewFile ; if ( sha ) { changeNewFile = Change . createCreateFromSha ( sha ) ; } else { // Content not available as blob const blob = <mask> ( repoState , filepath ) ; const contentBuffer = blob . getAsBuffer ( ) ; changeNewFile = Change . createCreate ( contentBuffer ) ; } // Remove old file const removedRepoState = remove ( repoState , filepath ) ; // Add new file return ChangeUtils . setChange ( removedRepoState , newFilepath , changeNewFile ) ; }