1. 먼저 ComLock 의 개발 목적은 이러합니다
ComLock 은 악성코드 나 에드웨어등 잡 프로그램이 동시 설치되지 않습니다.
; Script generated by the HM NIS Edit Script Wizard.
; HM NIS Edit Wizard helper defines
!define PRODUCT_NAME "comlock"
!define PRODUCT_VERSION "2.2.0.7"
!define PRODUCT_PUBLISHER "byungjun4458"
!define PRODUCT_WEB_SITE "https://leebyungjun4458.wixsite.com/comlock"
!define PRODUCT_DIR_REGKEY "Software\Microsoft\Windows\CurrentVersion\App Paths\컴퓨터 잠금 프로그램.exe"
!define PRODUCT_UNINST_KEY "Software\Microsoft\Windows\CurrentVersion\Uninstall\${PRODUCT_NAME}"
!define PRODUCT_UNINST_ROOT_KEY "HKLM"
!define PRODUCT_STARTMENU_REGVAL "NSIS:StartMenuDir"
; MUI 1.67 compatible ------
!include "MUI.nsh"
; MUI Settings
!define MUI_ABORTWARNING
!define MUI_ICON "${NSISDIR}\Contrib\Graphics\Icons\modern-install.ico"
!define MUI_UNICON "${NSISDIR}\Contrib\Graphics\Icons\modern-uninstall.ico"
; Welcome page
!insertmacro MUI_PAGE_WELCOME
; License page
!define MUI_LICENSEPAGE_CHECKBOX
!insertmacro MUI_PAGE_LICENSE "이용약관.txt"
; Components page
!insertmacro MUI_PAGE_COMPONENTS
; Directory page
!insertmacro MUI_PAGE_DIRECTORY
; Start menu page
var ICONS_GROUP
!define MUI_STARTMENUPAGE_NODISABLE
!define MUI_STARTMENUPAGE_DEFAULTFOLDER "comlock"
!define MUI_STARTMENUPAGE_REGISTRY_ROOT "${PRODUCT_UNINST_ROOT_KEY}"
!define MUI_STARTMENUPAGE_REGISTRY_KEY "${PRODUCT_UNINST_KEY}"
!define MUI_STARTMENUPAGE_REGISTRY_VALUENAME "${PRODUCT_STARTMENU_REGVAL}"
!insertmacro MUI_PAGE_STARTMENU Application $ICONS_GROUP
; Instfiles page
!insertmacro MUI_PAGE_INSTFILES
; Finish page
!define MUI_FINISHPAGE_RUN "$INSTDIR\comlock 설정.exe"
!define MUI_FINISHPAGE_SHOWREADME "$DESKTOP\읽어주세요.txt"
!insertmacro MUI_PAGE_FINISH
; Uninstaller pages
!insertmacro MUI_UNPAGE_INSTFILES
; Language files
!insertmacro MUI_LANGUAGE "Korean"
; MUI end ------
Name "${PRODUCT_NAME} ${PRODUCT_VERSION}"
OutFile "Setup.exe"
InstallDir "$PROGRAMFILES\comlock"
InstallDirRegKey HKLM "${PRODUCT_DIR_REGKEY}" ""
ShowInstDetails show
ShowUnInstDetails show
Section "comlock" SEC01
SetOutPath "$INSTDIR"
SetOverwrite ifnewer
File "컴퓨터 잠금 프로그램.exe"
File "comlock 설정.exe"
SetOutPath "$APPDATA"
File "comlcok.ini"
File "comset.ini"
; Shortcuts
!insertmacro MUI_STARTMENU_WRITE_BEGIN Application
CreateDirectory "$SMPROGRAMS\$ICONS_GROUP"
CreateShortCut "$SMPROGRAMS\$ICONS_GROUP\comlock.lnk" "$INSTDIR\컴퓨터 잠금 프로그램.exe"
CreateShortCut "$DESKTOP\comlock.lnk" "$INSTDIR\컴퓨터 잠금 프로그램.exe"
CreateShortCut "$SMPROGRAMS\$ICONS_GROUP\comlock설정.lnk" "$INSTDIR\comlock 설정.exe"
CreateShortCut "$DESKTOP\comlock설정.lnk" "$INSTDIR\comlock 설정.exe"
!insertmacro MUI_STARTMENU_WRITE_END
SectionEnd
Section "fonts" SEC02
SetOutPath "$FONTS"
File "필수 설치\휴먼태엑스포.ttf"
File "필수 설치\휴먼굵은샘체.ttf"
File "필수 설치\헤움버블S.ttf"
File "필수 설치\Typo_DecoVariety.ttf"
File "필수 설치\Typo_DecoSolid.ttf"
File "필수 설치\HY견고딕.TTF"
; Shortcuts
!insertmacro MUI_STARTMENU_WRITE_BEGIN Application
!insertmacro MUI_STARTMENU_WRITE_END
SectionEnd
Section "help" SEC03
SetOutPath "$DESKTOP"
File "읽어주세요.txt"
; Shortcuts
!insertmacro MUI_STARTMENU_WRITE_BEGIN Application
!insertmacro MUI_STARTMENU_WRITE_END
SectionEnd
Section -AdditionalIcons
SetOutPath $INSTDIR
!insertmacro MUI_STARTMENU_WRITE_BEGIN Application
WriteIniStr "$INSTDIR\${PRODUCT_NAME}.url" "InternetShortcut" "URL" "${PRODUCT_WEB_SITE}"
CreateShortCut "$SMPROGRAMS\$ICONS_GROUP\Website.lnk" "$INSTDIR\${PRODUCT_NAME}.url"
CreateShortCut "$SMPROGRAMS\$ICONS_GROUP\Uninstall.lnk" "$INSTDIR\uninst.exe"
!insertmacro MUI_STARTMENU_WRITE_END
SectionEnd
Section -Post
WriteUninstaller "$INSTDIR\uninst.exe"
WriteRegStr HKLM "${PRODUCT_DIR_REGKEY}" "" "$INSTDIR\컴퓨터 잠금 프로그램.exe"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "DisplayName" "$(^Name)"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "UninstallString" "$INSTDIR\uninst.exe"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "DisplayIcon" "$INSTDIR\컴퓨터 잠금 프로그램.exe"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "DisplayVersion" "${PRODUCT_VERSION}"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "URLInfoAbout" "${PRODUCT_WEB_SITE}"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "Publisher" "${PRODUCT_PUBLISHER}"
SectionEnd
; Section descriptions
!insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
!insertmacro MUI_DESCRIPTION_TEXT ${SEC01} "comlock/comlock설정 이 설치됩니다"
!insertmacro MUI_DESCRIPTION_TEXT ${SEC02} "comlock 에 필요한 폰트가 설치됩니다"
!insertmacro MUI_DESCRIPTION_TEXT ${SEC03} "comlock 도움말 텍스트 파일이 설치됩니다"
!insertmacro MUI_FUNCTION_DESCRIPTION_END
Function un.onUninstSuccess
HideWindow
MessageBox MB_ICONINFORMATION|MB_OK "$(^Name)는(은) 완전히 제거되었습니다."
FunctionEnd
Function un.onInit
MessageBox MB_ICONQUESTION|MB_YESNO|MB_DEFBUTTON2 "$(^Name)을(를) 제거하시겠습니까?" IDYES +2
Abort
FunctionEnd
Section Uninstall
!insertmacro MUI_STARTMENU_GETFOLDER "Application" $ICONS_GROUP
Delete "$INSTDIR\${PRODUCT_NAME}.url"
Delete "$INSTDIR\uninst.exe"
Delete "$DESKTOP\읽어주세요.txt"
Delete "$FONTS\HY견고딕.TTF"
Delete "$FONTS\Typo_DecoSolid.ttf"
Delete "$FONTS\Typo_DecoVariety.ttf"
Delete "$FONTS\헤움버블S.ttf"
Delete "$FONTS\휴먼굵은샘체.ttf"
Delete "$FONTS\휴먼태엑스포.ttf"
Delete "$APPDATA\comset.ini"
Delete "$APPDATA\comlcok.ini"
Delete "$INSTDIR\comlock 설정.exe"
Delete "$INSTDIR\컴퓨터 잠금 프로그램.exe"
Delete "$SMPROGRAMS\$ICONS_GROUP\Uninstall.lnk"
Delete "$SMPROGRAMS\$ICONS_GROUP\Website.lnk"
Delete "$DESKTOP\comlock설정.lnk"
Delete "$SMPROGRAMS\$ICONS_GROUP\comlock설정.lnk"
Delete "$DESKTOP\comlock.lnk"
Delete "$SMPROGRAMS\$ICONS_GROUP\comlock.lnk"
RMDir "$SMPROGRAMS\$ICONS_GROUP"
RMDir "$INSTDIR"
DeleteRegKey ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}"
DeleteRegKey HKLM "${PRODUCT_DIR_REGKEY}"
SetAutoClose true
SectionEnd
이 처럼 소스를 자신있게 공개할수 있기 때문에 안심하고 설치하셔도 좋습니다!.
그뒤로는 적으셔도 종료안됨......
감사합니다.