Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Rearranging Files in GAS Project (Restricted)

Rearranging Files in GAS Project (Restricted)

Introduction

Recently, I have introduced a GAS library and a CLI tool for rearranging files in GAS project. Those are RearrangeScripts and ggsrun. Because today, I found a new way for rearranging files, I would like to introduce it although there is a restriction.

By the recent Google-update, users become able to create folders in GAS project. The new way uses this. At first, please see the demonstration GIF animation.

Demo

Explanation

When at the default project, files in the project cannot be moved using a mouse. When a folder is created, the files can be moved by the drag-and-drop operation. But, at outside of the folder, even if files are rearranged by a mouse, when the project is reopened, the rearranged files are reset.

At the new way, it creates a folder and imports files in the folder. By this, when the files in the folder are rearranged, even if the project is reopened, the rearranged files are NOT reset.

The condition of folder is saved. So when the folder is opened, the folder is kept to open, even if the project is reopened.

Restriction

However, there is a restriction for this new way. When the cookie of browser is cleared, the folder information of the project is removed. So the rearranged files are back to the original arrangement.

If you want to permanently rearrange files in project, you can use the GAS library and CLI tool.

I would like to expect this restriction is removed in the future update.

If this will be useful for you, I'm glad.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment