{"id":18887289,"url":"https://github.com/liberxue/unzip","last_synced_at":"2025-07-13T22:06:41.547Z","repository":{"id":107564207,"uuid":"93468589","full_name":"Liberxue/UNZip","owner":"Liberxue","description":"Self extracting Csharp zipclass UNzipclass ","archived":false,"fork":false,"pushed_at":"2019-08-09T01:57:52.000Z","size":4250,"stargazers_count":0,"open_issues_count":7,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-12-31T05:19:36.050Z","etag":null,"topics":["bzip2","corezip","gzip","tar","unzip","unzipping-files","zipcode","zipfile"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Liberxue.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,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-06-06T02:47:13.000Z","updated_at":"2017-07-14T15:32:31.000Z","dependencies_parsed_at":"2023-06-08T12:30:34.783Z","dependency_job_id":null,"html_url":"https://github.com/Liberxue/UNZip","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Liberxue%2FUNZip","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Liberxue%2FUNZip/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Liberxue%2FUNZip/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Liberxue%2FUNZip/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Liberxue","download_url":"https://codeload.github.com/Liberxue/UNZip/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239859562,"owners_count":19708863,"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":["bzip2","corezip","gzip","tar","unzip","unzipping-files","zipcode","zipfile"],"created_at":"2024-11-08T07:36:12.394Z","updated_at":"2025-02-20T15:13:45.570Z","avatar_url":"https://github.com/Liberxue.png","language":"C#","readme":"# UNZip\nSelf extracting Csharp zipclass UNzipclass \n\n- Support zip\n- Giz compression \n- encryption folder\n- compressed file\n- single compression\nself release file, applied in c# custom installation package\n\n![image description](UI-img/form1.png)\n![image description](UI-img/form2.png)\n\n- c# unzip demo code\n\n```\n private System.Collections.Specialized.StringCollection folderCol;\n        private static ZipClass zipClass = new ZipClass();  //压缩工具类\n        private static UnZipClass unZipC = new UnZipClass();  //解压缩类\n        public Form2()\n        {\n            InitializeComponent();\n            //AppDomain.CurrentDomain.AssemblyResolve += new ResolveEventHandler(CurrentDomain_AssemblyResolve);\n            InitializeComponent();\n            folderCol = new System.Collections.Specialized.StringCollection();\n        }\n        ///// \u003csummary\u003e\n        ///// 判断文件是否是zip\n        ///// \u003c/summary\u003e\n        ///// \u003cparam name=\"zipFile\"\u003e\u003c/param\u003e\n        ///// \u003creturns\u003e\u003c/returns\u003e\n        //private bool isZipFile(string zipFile)\n        //{\n        //    if (\".zip\" == zipFile.Substring(zipFile.Length - 4, 4))\n        //    {\n        //        return true;\n        //    }\n        //    return false;\n\n        //}\n        /// \u003csummary\u003e\n        /// 显示信息 byliberxue 全局显示\n        /// \u003c/summary\u003e\n        /// \u003cparam name=\"titile\"\u003e\u003c/param\u003e\n        /// \u003cparam name=\"content\"\u003e\u003c/param\u003e\n        private void showMsg(string titile, string content)\n        {\n            MessageBox.Show(titile + \"\" + content);\n\n        }\n        //获取文件目录\n        private string  getZipToDir(string zipToFile)\n        {\n            string files = \"\";\n\n            //for (int i = 0; i \u003c selectFiles; i++)\n            //{\n            //    string fileName = listViewFilesAndFolders.SelectedItems[i].Text;\n            //    //文件夹目录\n            //    string dir = listViewFilesAndFolders.SelectedItems[i].Tag.ToString();\n            //    //全路径名\n            //    string fullName = dir + fileName;\n            //    //选择一个直接返回\n            //    if (listViewFilesAndFolders.SelectedItems.Count == 1)\n            //    {\n            //        return fullName;\n            //    }\n            //    if (i \u003c listViewFilesAndFolders.SelectedItems.Count - 1)\n            //    {\n            //        files += fullName + \"%\";  //文件之间用%分开\n            //    }\n            //    else\n            //    {\n            //        files += fullName;\n            //    }\n\n            //}\n\n            return files;\n        }\n        private void button1_Click(object sender, System.EventArgs e)\n        {\n            string selectFiles = currentPath.Text.ToString();\n            string zipToFile = SaveFileTextBox.Text;   //压缩到哪个目录下\n            //判断保存的文件是否是Zip文件\n            if (isZipFile(zipToFile))\n            {\n                if (zipClass.Zip(selectFiles, zipToFile, \"123\"))\n                {\n\n                    showMsg(\"压缩成功\", \"\");\n                    //取得文件所在文件夹\n                    string zipDir = this.getZipToDir(zipToFile);\n\n                    //PaintListView(zipDir + \"\\\\\");\n                    //folderCol.Add(zipDir + \"\\\\\");\n                    SaveFileTextBox.Text = \"\";\n                    currentPath.Text = \"\";\n                }\n                else\n                {\n                    showMsg(\"压缩失败\", \"\");\n                }\n            }\n            else\n            {\n                showMsg(\"请输入正确的.zip文件（后缀.zip）\", \"\");\n            }\n        }\n```\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fliberxue%2Funzip","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fliberxue%2Funzip","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fliberxue%2Funzip/lists"}