This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| source /opt/bbsage/current/libbsfl.sh | |
| function folder_empty() { #@ Returns 0 if folder is empty and 1 if it is not. | |
| if [[ ! "$(ls -A $1)" ]]; then | |
| return 0 | |
| else | |
| return 1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from mint.xml.XmlObjectKit import make_xml_backed_class | |
| Entity = make_xml_backed_class('entity',['name','description'],['id']) | |
| e1 = Entity() | |
| e1.name = "First Entity" | |
| e1.description = "My First Entity." | |
| e1.id = 123 | |
| xml_str = e1.to_xml() | |
| print xml_str |