{"id":22886457,"url":"https://github.com/willdev12/sheetmerge","last_synced_at":"2025-05-07T10:27:30.790Z","repository":{"id":92142781,"uuid":"597199463","full_name":"WillDev12/SheetMerge","owner":"WillDev12","description":"SheetMerge allows you to program multiple Google Sheets at once minus the hassle of defining hundreds of things.","archived":false,"fork":false,"pushed_at":"2023-11-27T17:22:27.000Z","size":65,"stargazers_count":6,"open_issues_count":0,"forks_count":2,"subscribers_count":1,"default_branch":"main","last_synced_at":"2023-11-27T18:27:56.139Z","etag":null,"topics":["google","google-library","google-script","google-script-library","google-scripts","google-sheet","google-sheets","google-sheets-api","google-sheets-api-v4","google-sheets-custom-function","google-sheets-gs","google-sheets-library","libraries","libraries-data","library"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/WillDev12.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-02-03T21:10:46.000Z","updated_at":"2023-06-13T02:55:20.000Z","dependencies_parsed_at":"2023-03-03T12:15:37.905Z","dependency_job_id":null,"html_url":"https://github.com/WillDev12/SheetMerge","commit_stats":null,"previous_names":[],"tags_count":2,"template":null,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WillDev12%2FSheetMerge","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WillDev12%2FSheetMerge/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WillDev12%2FSheetMerge/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WillDev12%2FSheetMerge/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/WillDev12","download_url":"https://codeload.github.com/WillDev12/SheetMerge/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":229609017,"owners_count":18098109,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["google","google-library","google-script","google-script-library","google-scripts","google-sheet","google-sheets","google-sheets-api","google-sheets-api-v4","google-sheets-custom-function","google-sheets-gs","google-sheets-library","libraries","libraries-data","library"],"created_at":"2024-12-13T20:18:51.241Z","updated_at":"2024-12-13T20:18:51.664Z","avatar_url":"https://github.com/WillDev12.png","language":"JavaScript","readme":"\u003cp align=\"center\"\u003e\u003cimg src=\"https://camo.githubusercontent.com/8b3ff7d037bfd150af02ae206242e91dcda05e19435f693f92eef01147b5ad23/68747470733a2f2f696d672e69636f6e73382e636f6d2f637574652d636c69706172742f3531322f676f6f676c652d7368656574732e706e67\" width=\"300\" height=\"320\"\u003e\u003c/p\u003e\n\u003cp align=\"center\"\u003e\n\n  \u003ca href=\"https://github.com/WillDev12\"\u003e\n    \u003cimg src=\"https://img.shields.io/github/followers/WillDev12?color=success\u0026label=Follow%20My%20Github\u0026logo=GitHub\u0026style=for-the-badge\"\u003e\n    \n  \u003ca href=\"https://github.com/WillDev12/SheetMerge\"\u003e\n    \u003cimg src=\"https://img.shields.io/github/forks/WillDev12/SheetMerge?style=for-the-badge\"\u003e\n    \n  \u003ca href=\"https://github.com/WillDev12/SheetMerge\"\u003e\n    \u003cimg src=\"https://img.shields.io/github/watchers/WillDev12/SheetMerge?style=for-the-badge\"\u003e\n  \n  \u003ca href=\"https://github.com/WillDev12/SheetMerge\"\u003e\n    \u003cimg src=\"https://img.shields.io/github/stars/WillDev12/SheetMerge?style=for-the-badge\"\u003e\n   \n\u003c/p\u003e\n\n# SheetMerge\n\nSheetMerge allows you to program multiple Google Sheets at once minus the hassle of defining hundreds of things.\n\n# How to install\n\nHere is a brief tutorial on how to install. If you are interested in how to use, see [here](https://github.com/WillDev12/SheetMerge#how-to-use)\n\n1. Go to Google Sheets\n\n2. Open new Google Script through Extensions\n\n3. Once in the script, click the plus button above \"Libraries\"\n\n4. Paste the following ID and press look up:\n\n```\n1MYnIAX-fSzeMQXHUGTrphcyFiwcSCC-fybI4CjqWj7Yv_E_5EymHxiAa\n```\n5. Select a version and apply\n\n# How to use\n\nSheetMerge provides custom commands that let you define what you want to do to another Google Sheet.  In other words, you can edit two at once.\n\nFirst, you will need a link.  In my case, I will use %link% as a replacement for an actual one.\n\nHere is an example of how to pair a new sheet:\n\n``` javascript\nvar link = \"%link%\";\n\nfunction yourFunction() {\n\n  var active = SheetMerge.getActiveSheet(link);\n  Logger.log(active);\n  \n}\n```\n\nIf the logger logs the active sheet used in the link, than the program is fully installed.\n\nThere are many more things you can do besides this, and [here](https://github.com/WillDev12/SheetMerge#there-is-much-more-than-just-that-so-here-is-a-full-list-of-pre-built-functions-provided) is a full list of all of them\n\n- - -\n\nHere is a script on how to get the properties of a cell:\n\n``` javascript\nvar link = \"%link%\";\n\nfunction getValues() {\n\n  let text = SheetMerge.getValue(\"A1\", link),\n      font = SheetMerge.getFontFamily(\"A1\", link),\n      size = SheetMerge.getFontSize(\"A1\", link);\n\n  Logger.log(text + \", \" + font + \", \" + size);\n\n}\n```\n\nIf you do not already have a sheet to edit, you can easily make one like this:\n``` javascript\nfunction createNew() {\n\n  var sheet = SheetMerge.createNew('name'); //upon running, this returns the url of the new sheet for you to edit.\n\n}\n```\n\nYou can even use the SheetMerge library to edit the sheet remotely!\n\n``` javascript\nfunction changeText() {\n\n  SheetMerge.setCell(\"A1\", \"Test text\", link);\n  Logger.log(SheetMerge.getValue(\"A1\", link));\n\n}\n```\n\n- - -\n\nEditing Sheets are easy when it comes to SheetMerge\n\n``` javascript\nvar link = \"%link%\";\n\nfunction editSheets() {\n\n  var name = SheetMerge.getSheetName(link);\n  var id = SheetMerge.getSheetId(link);\n\n  //Gets the name and id of the open sheet remotely\n\n  SheetMerge.renameActiveSheet(\"newName\", link);\n\n  //Renames the sheet of your choice\n\n  SheetMerge.insertSheet(\"sheetName\", link);\n  SheetMerge.copySheet(\"newName\", link);\n  SheetMerge.duplicateActiveSheet(link);\n\n  //Insert and copy sheets\n\n  SheetMerge.deleteActiveSheet(link);\n  SheetMerge.deleteSheet(\"sheetName\", link);\n\n  //Delete unnecessary ones\n\n}\n```\n\n- - -\n\nLots of font work is involved, so be warned!\n\n``` javascript\nvar link = \"%link%\";\n\nfunction getFonts() {\n\n  let color = SheetMerge.getFontColor(\"A1\", link),\n      size = SheetMerge.getFontSize(\"A1\", link),\n      style = SheetMerge.getFontStyle(\"A1\", link),\n      weight = SheetMerge.getFontWeight(\"A1\", link),\n      family = SheetMerge.getFontFamily(\"A1\", link);\n\n  //Get font properties\n\n  SheetMerge.setFontColor(\"A1\", \"#fff\", link);\n  SheetMerge.setCellFontSize(\"A1\", \"10\", link);\n  SheetMerge.setFontStyle(\"A1\", \"italic\", link);\n  SheetMerge.setFontWeight(\"A1\", \"bold\", link);\n  SheetMerge.setFontFamily(\"A1\", \"times new roman\", link);\n\n  //Change font properties\n\n}\n```\n\n- - -\n\n# There is much more than just that, so here is a full list of pre-built functions provided:\n\n| Property | Type | Description |\n| :---    | :----: | :----: |\n| getActiveSheet(link) | Sheets | Gets the current sheet of a Spreadsheet |\n| getSpreadsheetName(link) | Sheets | Gets the name of a spreadsheet from a link |\n| getSpreadsheetID(link) | Sheets | Gets the ID of a sheet from it's link |\n| copySpreadsheet(newName) | Sheets | This function copies the active spreadsheet and allows users to provide a custom name for the copied spreadsheet. |\n| copySpreadsheet() | Sheets | This function copies the active spreadsheet and automatically names the copy as \"Copy of [original spreadsheet name]\" |\n| copySheet(sourceSheet, newSheetName) | Sheets | This function copies a specific sheet within the active spreadsheet and assigns a new name to the copied sheet. |\n| getSheetUrl() | Sheets | This function retrieves the URL of the active spreadsheet |\n| getSheetName(link) | Sheets | Gets the name of the active sheet |\n| getURL(id) | Sheets | Gets the url of a Spreadsheet from the ID |\n| copySheet(newname, link) | Sheets | Copies a Spreadsheet |\n| deleteActiveSheet(link) | Sheets | Deletes the active sheet |\n| deleteSheet(sheetName, link) | Sheets | Deletes a sheet by its name |\n| duplicateActiveSheet(link) | Sheets | Duplicates the active sheet |\n| renameActiveSheet(newName, link) | Sheets | Renames the active sheet |\n| insertSheet(name, link) | Sheets | Inserts a new sheet |\n| getviewers(link) | People | Gets a list of all the active viewers and their emails |\n| getOwner(link) | People | Gets the owner of the document |\n| getA1(range, link) | Cells | Gets the A1 notation of a range |\n| getCellBorder(range, link) | Cells | Gets the border style of a range |\n| getFontColor(range, link) | Cells | Gets the font color of a range |\n| getFontSize(range, link) | Cells | Gets the font size of a range |\n| getCellRow(range, link) | Cells | Gets the row position of a range |\n| getCellColumn(range, link) | Cells | Gets the column position of a range |\n| getValue(range, link) | Cells | Gets the text of a cell or range |\n| getLastColumn(range, link) | Surroundings | Gets the last column used in the spreadsheet |\n| getLastRow(range, link) | Surroundings | Gets the last row used in the spreadsheet |\n| getFontStyle(range, link) | Fonts | Gets the font style of a range |\n| getFontFamily(range, link) | Fonts | Gets the font of a range |\n| getFontWeight(range, link) | Fonts | Gets the font weight of a range |\n| setCell(cell, text, link) | Setting | Sets a cell's text |\n| setCellBorder(range, top, left, bottom, right, link) | Setting | Sets the border weight of a range |\n| setCellFontSize(cell, size, link) | Setting | Sets the font size of a cell/range |\n| setFontColor(range, color, link) | Setting | Sets the font color of a cell/range |\n| setFontStyle(range, style, link) | Setting | Sets the font style of a cell/range |\n| setFontFamily(range, font, link) | Setting | Sets the font of a cell/range |\n| setFontWeight(range, weight, link) | Setting | Sets the font weight of a cell/range |\n| setRowHeight(row, height, link) | Setting | Sets the height of a specified row |\n| setColumnWidth(column, width, link) | Setting | Sets the width of a specified column |\n| setFormula(range, formula, link) | Formulas | Sets the fomula of a cell |\n| getFormula(range, link) | Formulas | Retrieves the formula of a cell |\n| clearRange(range, link) | Deletion | Clears the text of a range |\n| deleteRow(rowNum, link) | Deletion | Deletes a row |\n| deleteRows(row, howMany, link) | Deletion | Deletes multiple rows |\n| deleteColumn(columnNum, link) | Deletion | Deletes a column |\n| deleteColumns(column, howMany, link) | Deletion | Deletes multiple columns |\n| setTabColor(color, link) | Misc | Honestly I don't even know what this one does either :'\u003e |\n\n# Source\n\n  You can view my source[^1] [here](https://github.com/WillDev12/SheetMerge/blob/main/library/lib.gs)\n  \n# Interested in this kind of content?\n\nCheck out my [profile](https://github.com/WillDev12) or share it! (This means a lot to me)\nAlso a huge thanks to my contributers!\n```\nhttps://github.com/WillDev12\nhttps://github.com/cloud-dark\n```\n  \n[^1]: Copyright © WillDev12 2023\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwilldev12%2Fsheetmerge","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwilldev12%2Fsheetmerge","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwilldev12%2Fsheetmerge/lists"}