1
0
Fork 0
mirror of https://github.com/roles-ansible/ansible_role_dotfiles.git synced 2024-08-16 16:09:49 +02:00

files -> gameplay

This commit is contained in:
L3D 2019-01-10 13:32:49 +01:00
parent a8afabbfa5
commit 5f942d2330
No known key found for this signature in database
GPG key ID: 2AC13F35B22B3962
6 changed files with 14 additions and 8 deletions

View file

@ -5,8 +5,8 @@ Ansible role to deploy some dotfiles which may be useful
Affected files: Affected files:
```ini ```ini
/etc/bash.bashrc /etc/bash.bashrc
.bashrc ~/.bashrc
.vimrc ~/.vimrc
``` ```
needed vars: needed vars:
--------------- ---------------

View file

@ -4,3 +4,7 @@ bash:
bashrc: '' bashrc: ''
nextcloud: false nextcloud: false
nm: false nm: false
pwgen: true
shell: "/bin/bash"
ps1: '$(if [[ $(id -u) -ne 0 ]];then echo "\[\033[01;33m\]"; else echo "\[\033[01;31m\]"; fi) $(if [[ $? == 0 ]]; then printf "\xE2\x9D\xA4"; fi) \[\033[01;32m\]\u\[\033[01;36m\]@\[\033[01;32m\]\H\[\033[01;34m\] <\A> \[\033[01;35m\] \j \[\033[01;36m\] \w \[\033[01;33m\]\n\[\033[01;33m\] $(git branch 2>/dev/null | sed -n "s/* \(.*\)/\1 /p")$\[\033[01;00m\] '

View file

@ -7,7 +7,7 @@
- name: Create a global bashrc configuration - name: Create a global bashrc configuration
copy: copy:
src: 'files/bash.bashrc' src: 'templates/bash.bashrc'
dest: '/etc/bash.bashrc' dest: '/etc/bash.bashrc'
owner: root owner: root
group: root group: root
@ -15,7 +15,7 @@
- name: Copy bashrc configuration to admin users - name: Copy bashrc configuration to admin users
template: template:
src: 'files/bashrc' src: 'templates/bashrc'
dest: '/home/{{ item }}/.bashrc' dest: '/home/{{ item }}/.bashrc'
owner: '{{ item }}' owner: '{{ item }}'
group: wheel group: wheel
@ -24,7 +24,7 @@
- name: Copy vimrc configuration to root - name: Copy vimrc configuration to root
copy: copy:
src: 'files/vimrc' src: 'templates/vimrc'
dest: '/root/.vimrc' dest: '/root/.vimrc'
owner: root owner: root
group: root group: root
@ -32,7 +32,7 @@
- name: Copy vimrc configuration to admin users - name: Copy vimrc configuration to admin users
copy: copy:
src: 'files/vimrc' src: 'templates/vimrc'
dest: '/home/{{ item }}/.vimrc' dest: '/home/{{ item }}/.vimrc'
owner: '{{ item }}' owner: '{{ item }}'
group: wheel group: wheel

View file

@ -47,7 +47,7 @@ if [ -z "$BASHRCSOURCED" ]; then
# and console windows # and console windows
# If you want to do so, just add e.g. # If you want to do so, just add e.g.
if [ "$PS1" ]; then if [ "$PS1" ]; then
PS1='$(if [[ $(id -u) -ne 0 ]];then echo "\[\033[01;33m\]"; else echo "\[\033[01;31m\]"; fi) $(if [[ $? == 0 ]]; then printf "\xE2\x9D\xA4"; fi) \[\033[01;32m\]\u\[\033[01;36m\]@\[\033[01;32m\]\H\[\033[01;34m\] <\A> \[\033[01;35m\] \j \[\033[01;36m\] \w \[\033[01;33m\]\n\[\033[01;33m\] $(git branch 2>/dev/null | sed -n "s/* \(.*\)/\1 /p")$\[\033[01;00m\] ' PS1='{{ bash.ps1 }}'
fi fi
# to your custom modification shell script in /etc/profile.d/ directory # to your custom modification shell script in /etc/profile.d/ directory
fi fi
@ -77,7 +77,7 @@ if [ -z "$BASHRCSOURCED" ]; then
umask 022 umask 022
fi fi
SHELL=/bin/bash SHELL={{ bash.shell }}
# Only display echos from profile.d scripts if we are no login shell # Only display echos from profile.d scripts if we are no login shell
# and interactive - otherwise just process them to set envvars # and interactive - otherwise just process them to set envvars
for i in /etc/profile.d/*.sh; do for i in /etc/profile.d/*.sh; do
@ -111,4 +111,6 @@ alias ll='ls -la'
alias la='ls -A' alias la='ls -A'
alias l='ls -CF' alias l='ls -CF'
{% if bash.pwgen %}alias pwgen="/usr/bin/pwgen --num-passwords=3000 --numerals --capitalize --secure --no-vowels --symbols 42 | grep -v '0' | grep -v 'o' | grep -v 'O' | grep -v '\"' | grep -v 'I' | grep -v 'l' | grep -v '1' | grep -v '´' | grep -v '@' | tail -1 "{% endif %}
# vim:ts=4:sw=4 # vim:ts=4:sw=4