Create icon with: Target: C:\cygwin\bin\run.exe /usr/bin/bash.exe -l -c /usr/bin/startxwin.exe C:\cygwin64\bin\run.exe --quote /usr/bin/bash.exe -l -c "/usr/bin/startxwin -- -nolock" Start in: C:\cygwin\bin --------------------------------- create a file ".startxwinrc" in home directory of your cygwin account: #! /bin/bash echo $PATH #DISPLAY=127.0.0.1:0.0 #CYGWIN_ROOT=\cygwin #RUN=%CYGWIN_ROOT%\bin\run -p /usr/bin #PATH=.;%CYGWIN_ROOT%\bin;%PATH% # %RUN% XWin -multiwindow -clipboard -silent-dup-error # Startup an xterm, using bash as the shell. xterm -ls -sb +tb -sl 9999 -bg yellow -e /usr/bin/bash -l -------------------------------------------- create a file ".bashrc" in home directory of your cygwin account: # ~/.bashrc: executed by bash(1) for non-login shells. # see /usr/share/doc/bash/examples/startup-files (in the package bash-doc) # for examples # If not running interactively, don't do anything [ -z "$PS1" ] && return # Don't use ^D to exit set -o ignoreeof # don't put duplicate lines or lines starting with space in the history. # See bash(1) for more options HISTCONTROL=ignoreboth # append to the history file, don't overwrite it shopt -s histappend # for setting history length see HISTSIZE and HISTFILESIZE in bash(1) HISTSIZE=1000 HISTFILESIZE=2000 # check the window size after each command and, if necessary, # update the values of LINES and COLUMNS. shopt -s checkwinsize # If set, the pattern "**" used in a pathname expansion context will # match all files and zero or more directories and subdirectories. #shopt -s globstar # If set, a pattern that doesn't match anything returns nothing. Affects name completion ##shopt -s nullglob # make less more friendly for non-text input files, see lesspipe(1) [ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)" # set variable identifying the chroot you work in (used in the prompt below) if [ -z "$debian_chroot" ] && [ -r /etc/debian_chroot ]; then debian_chroot=$(cat /etc/debian_chroot) fi # set a fancy prompt (non-color, unless we know we "want" color) case "$TERM" in xterm-color) color_prompt=yes;; esac # uncomment for a colored prompt, if the terminal has the capability; turned # off by default to not distract the user: the focus in a terminal window # should be on the output of commands, not on the prompt #force_color_prompt=yes if [ -n "$force_color_prompt" ]; then if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then # We have color support; assume it's compliant with Ecma-48 # (ISO/IEC-6429). (Lack of such support is extremely rare, and such # a case would tend to support setf rather than setaf.) color_prompt=yes else color_prompt= fi fi if [ "$color_prompt" = yes ]; then # PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ ' PS1='\[\e]0;\w\a\]\n\[\e[36m\]\u@\h \[\e[34m\]\w\[\e[31m\]-\j\[\e[0m\]\n\$ ' else # PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ ' PS1='\[\e]0;\w\a\]\n\[\e[36m\]\u@\h \[\e[34m\]\w\[\e[31m\]-\j\[\e[0m\]\n\$ ' fi unset color_prompt force_color_prompt # If this is an xterm set the title to user@host:dir case "$TERM" in xterm*|rxvt*) PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1" ;; *) ;; esac # enable color support of ls and also add handy aliases if [ -x /usr/bin/dircolors ]; then test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)" alias ls='ls --color=auto' #alias dir='dir --color=auto' #alias vdir='vdir --color=auto' alias grep='grep --color=auto' alias fgrep='fgrep --color=auto' alias egrep='egrep --color=auto' fi # some more ls aliases alias ll='ls -alF' alias la='ls -A' alias l='ls -CF' alias x='xterm -ls -sb -sl 9999 &' alias sdweb='xterm -sb -sl 9999 -e ssh squaree8@squaredancingrochester.org &' alias ls='ls -F' # Add an "alert" alias for long running commands. Use like so: # sleep 10; alert alias alert='notify-send --urgency=low -i "$([ $? = 0 ] && echo terminal || echo error)" "$(history|tail -n1|sed -e '\''s/^\s*[0-9]\+\s*//;s/[;&|]\s*alert$//'\'')"' # Alias definitions. # You may want to put all your additions into a separate file like # ~/.bash_aliases, instead of adding them here directly. # See /usr/share/doc/bash-doc/examples in the bash-doc package. if [ -f ~/.bash_aliases ]; then . ~/.bash_aliases fi # enable programmable completion features (you don't need to enable # this, if it's already enabled in /etc/bash.bashrc and /etc/profile # sources /etc/bash.bashrc). if [ -f /etc/bash_completion ] && ! shopt -oq posix; then . /etc/bash_completion fi -------------------------------------------------------------------- create a file ".emacs" in home directory of your cygwin account: ;; Default .emacs file for JDE (setq inhibit-startup-message t) (set-scroll-bar-mode 'left) ;;; allow copy paste from firefox etc. (setq x-select-enable-clipboard t) (setq interprogram-paste-function 'x-cut-buffer-or-selection-value) '(setq select-active-regions nil) '(setq mouse-drag-copy-region t) (setq x-select-enable-primary t) '(setq mouse-yank-at-click [mouse-2]) '(setq x-select-enable-clipboard-manager nil) '(global-set-key [mouse-2] 'mouse-yank-primary) (setq search-whitespace-regexp nil) '(load-file "~fyj/pub/tools/emacs_jde-jpc") '(setq user-init-file (expand-file-name "init.el" (expand-file-name ".xemacs" "~"))) '(setq custom-file (expand-file-name "custom.el" (expand-file-name ".xemacs" "~"))) '(load-file user-init-file) '(load-file custom-file) (custom-set-variables ;; custom-set-variables was added by Custom. ;; If you edit it by hand, you could mess it up, so be careful. ;; Your init file should contain only one such instance. ;; If there is more than one, they won't work right. '(buffers-menu-max-size 100) '(c-basic-offset 2) '(indent-tabs-mode nil) '(initial-scratch-message "") '(menu-bar-mode t) '(mouse-wheel-mode t nil (mwheel)) '(mouse-wheel-progressive-speed nil) '(tex-fontify-script nil)) '( ''(set-background-color "black") ''(set-foreground-color "white") ''(set-cursor-color "red") ''(set-default-font "*-fixed-bold-r-*-13-*") '(set-default-font "*-fixed-bold-r-*-15-*") '(set-default-font "*-r-*-24-*") ) (custom-set-faces ;; custom-set-faces was added by Custom. ;; If you edit it by hand, you could mess it up, so be careful. ;; Your init file should contain only one such instance. ;; If there is more than one, they won't work right. ) '(set-default-font "-*-Courier-normal-r-*-*-13-*-*-*-c-*-*-iso8859-1") '(set-default-font "*-fixed-bold-r-*-13-*") (setq line-number-mode t) (global-font-lock-mode 1) (add-to-list 'default-frame-alist '(background-color . "black")) (add-to-list 'default-frame-alist '(foreground-color . "white")) (add-to-list 'default-frame-alist '(cursor-color . "red")) '(add-to-list 'default-frame-alist '(font . "7x13")) (add-to-list 'default-frame-alist '(font . "*-fixed-bold-r-*-13-*")) '(add-to-list 'default-frame-alist '(menu-font . "*-fixed-bold-r-*-13-*")) (setq initial-frame-alist default-frame-alist) ; for first frame (global-set-key "\eo" 'fill-nonuniform-paragraphs) (global-set-key "\ep" 'fill-individual-paragraphs) (require 'easymenu) (require 'cl) (require 'cc-mode) (defconst my-menu nil) (defvar my-flag t) ;; just for testing ;;; These is example actions for menu (defun my-1 () (interactive) (message "1") (setq my-flag t)) (defun my-2 () (interactive) (message "2") (setq my-flag nil)) (defun my-3 () (interactive) (message buffer-file-name)) (easy-menu-define my-menu java-mode-map ; the map "My test menu" ; documentation string (list "jde" ["Selection 1" my-1 t] ["Selection 2" my-2 t] ["Selection 3" my-3 my-flag ])) (add-hook 'java-mode-hook (lambda () (set (make-local-variable 'compile-command) (concat "javac " buffer-file-name)))) '(defcustom compile-command "make -k " "*Last shell command used to do a compilation; default for next compilation. Sometimes it is useful for files to supply local values for this variable. You might also use mode hooks to specify it in certain modes, like this: (add-hook 'c-mode-hook (lambda () (unless (or (file-exists-p \"makefile\") (file-exists-p \"Makefile\")) (set (make-local-variable 'compile-command) (concat \"make -k \" (file-name-sans-extension buffer-file-name))))))" :type 'string :group 'compilation) ;; ----------------------------- (put 'downcase-region 'disabled nil) -------------------------------------------------------------------- Part of my ".bashrc": alias rit='xterm -sb +tb -sl 9999 -e ssh -Y kayrun.cs.rit.edu -l swm &' alias rita='xterm -sb +tb -sl 9999 -e ssh -Y aragorn.cs.rit.edu -l swm &' alias ritd='xterm -sb +tb -sl 9999 -e ssh -Y donetsk.cs.rit.edu -l swm &' alias ritn='xterm -sb +tb -sl 9999 -e ssh -Y nial.cs.rit.edu -l swm &' alias ritq='xterm -sb +tb -sl 9999 -e ssh -Y queeg.cs.rit.edu -l swm &' alias ritp='xterm -sb +tb -sl 9999 -e ssh -Y paradise.cs.rit.edu -l swm &' alias ritm='xterm -sb +tb -sl 9999 -e ssh -Y merrick.cs.rit.edu -l swm &' alias ritg='xterm -sb +tb -sl 9999 -e ssh -Y glados.cs.rit.edu -l swm &' alias ritf='xterm -sb +tb -sl 9999 -e ssh -Y fibonacci.cs.rit.edu -l swm &' alias x='xterm -ls -sb +tb -sl 9999 &' alias ls='ls -F' DISPLAY=127.0.0.1:0.0 export DISPLAY PS1='\[\e]0;\w\a\]\n\[\e[36m\]\u@\h \[\e[34m\]\w\[\e[31m\]-\j\[\e[0m\]\n\$ ' PATH=${PATH}:/usr/X11R6/bin