Last active
August 29, 2015 14:27
-
-
Save nowri/e9279d3bc469d08187ff to your computer and use it in GitHub Desktop.
GASで非共有Driveファイルのオーナー権限を変更する ref: http://qiita.com/nowri/items/2d33f9ba580da52c913c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var file = DriveApp.getFileById("FILE_ID_HERE");//自分がオーナーのファイル | |
var targetMail = "new@example.org"; | |
var oldMail; | |
file.setOwner(targetMail); | |
oldMail = Session.getActiveUser().getEmail(); | |
file.removeEditor(oldMail); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment