clasp

Clasp Could not read API credentials. Are you logged in globally?

时光毁灭记忆、已成空白 提交于 2021-01-28 08:52:45
问题 I'm logging in with clasp login --creds <file> which produces a local .clasprc.json file. It says that I am logged in, but when I run another command I get: Could not read API credentials. Are you logged in globally? Any thoughts on why its not looking at my local clasprc file first? Currently using version clasp v. 2.2.0 回答1: I ran into the same problem on Windows 10 and found that you need to login both globally and locally to use clasp run . There should be a .clasprc.json file in both

TypeScript classes order in Google AppScript Project

一曲冷凌霜 提交于 2021-01-27 12:17:21
问题 Suppose we have 2 simple TypeScript classes in 2 separate files: B.ts: namespace A{ export abstract class ItemBase { id:number=432; } } C.ts ///<reference path="B.ts"/> namespace A{ export class ItemType extends A.ItemBase{} } and invoking code in Code.ts: ///<reference path="C.ts"/> let a:A.ItemType=new A.ItemType(); Everything works well after pushing it using clasp But if I change the name of the C.ts file to AA.ts, I would get the error: TypeError: Cannot read property "prototype" from

用Answer Set Programming解数独

落爺英雄遲暮 提交于 2020-08-19 23:27:27
搜索“ASP solver”可以得到若干个,clasp是其中一个 http://www.cs.uni-potsdam.de/clasp/?page=main 有本教程叫A User's Guide to gringo, clasp, clingo, and iclingo,Google一下就可以下到 Answer Set Programming的优点在于,你只需要定义规则,求解的方法由ASP solver来解决,这是一种declarative language,和SQL同类 看如下这个数独( http://www.sudoku.name/index-cn.php ): 首先描述facts(文件sudoku_fact.lp): row(1..9 ). col( 1..9 ). value( 1..9 ). put( 1,2,9 ). put( 1,4,7 ). put( 1,6,6 ). put( 1,7,1 ). put( 2,2,2 ). put( 2,3,5 ). put( 2,4,3 ). put( 2,8,6 ). put( 2,9,7 ). put( 3,3,6 ). put( 3,5,2 ). put( 3,8,8 ). put( 4,1,5 ). put( 4,6,9 ). put( 4,7,3 ). put( 5,1,7 ). put( 5,3,3 ). put(

Error retrieving access token: TypeError: Cannot read property 'project_id' of undefined

一个人想着一个人 提交于 2020-06-16 03:42:37
问题 I am new to clasp. After the initial login via: clasp login I am able to login to script.google.com Next, I have created a project and pushed the file via: clasp push Now, I have logged out using: clasp logout Help required here: Now, if I am trying: clasp login --creds ./.clasp.json I am getting, "Error retrieving access token: TypeError: Cannot read property 'project_id' of undefined". Please guide me on how to login via --creds? 回答1: TLDR: You're using the config file ( .clasp.json ), and

Error retrieving access token: TypeError: Cannot read property 'project_id' of undefined

我的未来我决定 提交于 2020-06-16 03:42:08
问题 I am new to clasp. After the initial login via: clasp login I am able to login to script.google.com Next, I have created a project and pushed the file via: clasp push Now, I have logged out using: clasp logout Help required here: Now, if I am trying: clasp login --creds ./.clasp.json I am getting, "Error retrieving access token: TypeError: Cannot read property 'project_id' of undefined". Please guide me on how to login via --creds? 回答1: TLDR: You're using the config file ( .clasp.json ), and

CLASP Local Login

一世执手 提交于 2020-05-15 06:52:05
问题 I'm trying to figure out how to set up a local login file for my google scripts project in order to set it up so it'll work in an automated deploy process. As far as I can tell, clasp login will create a file in your home directory which authenticates you with scripts.google.com, but that file isn't applicable to to local logins because it's missing some properties like "project_id". When looking for how to create a file to run with clasp login --creds {file} there doesn't seem to be a

Tool to compile Google App Script locally

风格不统一 提交于 2020-03-26 04:04:26
问题 I am developing a sheet add on using JavaScript framework and using clasp to push the files to google drive. The problem is that clasp push command fails for some JavaScript code by simply saying: code: 500, errors: [ { message: 'unknown error.', domain: 'global', reason: 'backenderror' } ] I think the App script doesn't allow certain JavaScript code. So I am looking for a tool that can compile the JavaScript code and Google App script code and point me the exact location of exception or at

Tool to compile Google App Script locally

孤人 提交于 2020-03-26 04:03:39
问题 I am developing a sheet add on using JavaScript framework and using clasp to push the files to google drive. The problem is that clasp push command fails for some JavaScript code by simply saying: code: 500, errors: [ { message: 'unknown error.', domain: 'global', reason: 'backenderror' } ] I think the App script doesn't allow certain JavaScript code. So I am looking for a tool that can compile the JavaScript code and Google App script code and point me the exact location of exception or at