Skip to content

Commit

Permalink
docs(samples): add region tags for sample browser (#474)
Browse files Browse the repository at this point in the history
  • Loading branch information
averikitsch authored Oct 21, 2020
1 parent 617ee59 commit 39d788b
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 0 deletions.
2 changes: 2 additions & 0 deletions cloud-tasks/createQueue.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@

'use strict';

// [START cloud_tasks_create_queue]
/**
* Create a new Task Queue
*/
Expand Down Expand Up @@ -45,6 +46,7 @@ async function createQueue(
});
console.log(`Created queue ${response.name}`);
}
// [END cloud_tasks_create_queue]

const args = process.argv.slice(2);
createQueue(...args).catch(console.error);
2 changes: 2 additions & 0 deletions cloud-tasks/deleteQueue.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@

'use strict';

// [START cloud_tasks_delete_queue]
/**
* Delete a given Queue
*/
Expand All @@ -35,6 +36,7 @@ async function deleteQueue(
await client.deleteQueue({name});
console.log(`Deleted queue '${queue}'.`);
}
// [END cloud_tasks_delete_queue]

const args = process.argv.slice(2);
deleteQueue(...args).catch(console.error);
2 changes: 2 additions & 0 deletions cloud-tasks/listQueues.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@

'use strict';

// [START cloud_tasks_list_queues]
async function listQueues(
project = 'my-project-id', // Your GCP Project id
location = 'us-central1' // The GCP region to search for queues
Expand All @@ -39,6 +40,7 @@ async function listQueues(
console.log('No queues found!');
}
}
// [END cloud_tasks_list_queues]

const args = process.argv.slice(2);
listQueues(...args).catch(console.error);

0 comments on commit 39d788b

Please sign in to comment.